Semantic versioning automation tool for software projects
Project description
Bumpify
Semantic versioning automation tool for software projects.
About
Bumpify is a CLI tool that analyzes VCS changelog of your project and generates next semantic version of it. Despite the fact that the tool is written in Python, it can be used to automate versioning of any project, written in any language, and any technology.
Bumpify works with conventional commits, as defined here:
https://www.conventionalcommits.org/en/v1.0.0/
And follows semantic versioning rules that can be found here:
Installation
Using pip
This is recommended option if you want to use this tool only inside your virtual Python environment as a development dependency of the project you work on:
$ pip install bumpify
Using pipx
This is recommended option if you want this tool to be available system wide:
$ pipx install bumpify
Usage
Creating initial configuration
Bumpify reads its configuration from a configuration file, that by default will
be created inside project's root directory and named .bumpify.toml
.
To create initial configuration for your project, proceed to the root directory of your project and type:
$ bumpify init
That command will interactively guide you through the process of creating initial configuration file.
Alternatively, you can also take a look at config file that Bumpify itself is using:
https://github.com/mwiatrzyk/bumpify/blob/main/.bumpify.toml
Yes, Bumpify is also versioned with Bumpify :-)
Create a new version
Once the project is configured, you can start using the tool. To bump the version and create new release just run following command:
$ bumpify bump
The bump
command will, among other things, do following:
- Check if version tags are present.
- Create initial version in no version tags are found.
- Create next version if version tags are found. The new version is calculated by analyzing VCS changelog between last version and VCS repository HEAD. Only conventional commits are currently taken into account, all other formats are ignored.
- Write new version to all configured version files.
- Create or update all configured changelog files.
- Create so called bump commit and add all modified files to it.
- Tag the bump commit with a version tag.
Bumpify will not push the commit and the tag to the upstream; you will have to do it on your own, as this is out of scope of Bumpify.
I strongly recommend calling bumpify bump
from one of the final CI steps of
your project.
Glossary
Conventional commit
A normalized format of a commit message that can be later parsed by tools like Bumpify and interpreted accordingly.
Here's an example:
feat: add support for Markdown changelog
Thanks to conventional commits Bumpify knows what changes are breaking changes, what are new features, and what are bug fixes. Based on that the tool can calculate next version and generate changelog.
Check here for more details:
https://www.conventionalcommits.org/en/v1.0.0/
Version file
Project's file containing project's version string. Version files are used to store project's version value, which must be adjusted on each version bump. There can be several such files inside a project and all should be known to Bumpify to avoid version integrity problems.
Changelog file
The file with release history of the project.
It is automatically created or updated on each version bump. Bumpify can create several changelog files, with different formats.
Currently supported changelog file formats are Markdown and JSON.
Bump commit
A commit created once version was bumped with message containing information about previous and new version. For example:
bump: 0.1.0 -> 0.2.0
The format of a bump commit can be changed in the config file.
Version tag
Each bump commit is tagged with a version tag. For example:
v1.2.3
The format of this tag can be changed in the config file.
License
The project is licensed under the terms of the MIT license.
Author
Maciej Wiatrzyk maciej.wiatrzyk@gmail.com
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
File details
Details for the file bumpify-0.3.0.tar.gz
.
File metadata
- Download URL: bumpify-0.3.0.tar.gz
- Upload date:
- Size: 38.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.8.2 CPython/3.11.9 Linux/5.15.0-1056-aws
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 4626cb8b403a4e7cc578c48a51f55227ea0d200210e4bb865f59a53ec92a96a2 |
|
MD5 | 357a82b706ee8e116886a4b750ed296c |
|
BLAKE2b-256 | 30e1577229a021d8d5e91c273eee1aaf3422587ea119ad0679978cb4907be337 |
File details
Details for the file bumpify-0.3.0-py3-none-any.whl
.
File metadata
- Download URL: bumpify-0.3.0-py3-none-any.whl
- Upload date:
- Size: 56.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.8.2 CPython/3.11.9 Linux/5.15.0-1056-aws
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | a3ddcf87f01eb1aafbee5125d4cfdc57680e6aa9b6b9025fdd46f807584919ff |
|
MD5 | 91f623559f14528cb2d35626c7d2e439 |
|
BLAKE2b-256 | a74f4a4f6a0b3469118a9046ec24620e5ff76f7f061ae62126e0d2b0403c2f01 |