Changeset management tool for Python projects
Project description
pychangeset
A tool for automating version bumps, changelog generation and release PRs in Python projects, inspired by Changesets.
Installation
# Use with uvx (recommended)
uvx changeset
# Or install from PyPI
pip install pychangeset
Quick Start
0. Initialize
uvx changeset
This will:
- Run
changeset init, creating a .changeset/ directory in your project - Prompt the user to
adda changeset, which will:- Detect which packages have changes
- Ask what type of change for each (major/minor/patch)
- Prompt for a description
- Create a changeset file in
.changeset/
1. Track .changset/
git add .changeset/
git commit -m "Add changeset"
git push
2. Automated Release Process
To get the most out of pychangeset, add these workflows to your repository:
.github/workflows/changesets.yml
When you merge to your main branch, the changesets workflow will create or update a Release PR with:
- Updated CHANGELOG.md files
- Bumped version numbers
- Consolidated PR description
.github/workflows/release.yml
When the Release PR is merged, the release workflow:
- Publishes packages to PyPI
- Creates git tags
- Creates GitHub releases
Commands
changeset init
Initialize changesets in your project.
changeset add / changeset
Create a new changeset interactively.
Options:
--all: Include all packages without prompting
changeset version
Process changesets and bump versions.
Options:
--dry-run: Preview changes without applying them--skip-changelog: Skip changelog generation
changeset changelog
Generate changelogs from changesets.
Options:
--dry-run: Preview changelog without writing files--output-pr-description <file>: Write PR description to file
changeset check-changeset
Check if changesets exist for the current branch (useful for CI).
Options:
--skip-ci: Skip check in CI environment
Changelog Format
Changelogs are generated with PR and commit metadata:
# package-name
## 1.2.0
### Minor Changes
- [#123](link-to-pr) [`abc123`](link-to-commit) Thanks @username! - Description of change
### Patch Changes
- [#124](link-to-pr) [`def456`](link-to-commit) Thanks @username! - Bug fix description
Development
# Clone the repository
git clone https://github.com/the-roaring/pychangeset.git
cd pychangeset
# Install with uv
uv sync
# Run tests
uv run pytest
# Run the tool locally
uv run changeset
License
MIT
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file changeset-0.2.7.tar.gz.
File metadata
- Download URL: changeset-0.2.7.tar.gz
- Upload date:
- Size: 37.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: uv/0.7.21
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
8339ba2a55c2222a5f80d03e03f2bf4b07966b152ae5c2520f5ca41af4a78ba6
|
|
| MD5 |
08843962ca5b2a28d96714366b420c6a
|
|
| BLAKE2b-256 |
bf2a8a2005afa1e44380a14af1fece9a8875a0dd1434d4cdde7a03b3d6f47622
|
File details
Details for the file changeset-0.2.7-py3-none-any.whl.
File metadata
- Download URL: changeset-0.2.7-py3-none-any.whl
- Upload date:
- Size: 19.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: uv/0.7.21
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
14a8adb6e068f281b3aca3954625e2f5a3c098671621595ed569b72daa50ded8
|
|
| MD5 |
0865216623096fdef03de88442c34abb
|
|
| BLAKE2b-256 |
00e599ab2b3763482705f8c06d0e55162ded729c74721ab9cdc4a853cc8ed65a
|