Manage properly semver in your repository
The easiest way to manage semantic versioning in your project and generate CHANGELOG.md file automatically.
Semversioner will provide the tooling to automate semver release process for libraries, docker images, etc.
This project was inspired by the way AWS manages their versioning for AWS-cli.
The semantic versioning spec involves several possible variations, but to simplify, in Semversioner we are using the three-part version number:
Constructed with the following guidelines:
- Breaking backward compatibility or major features bumps the major (and resets the minor and patch).
- New additions without breaking backward compatibility bumps the minor (and resets the patch).
- Bug fixes and misc changes bumps the patch.
An example would be 1.0.0
How it works
At any given time, the
.semversioner/ directory looks like:
.semversioner └── next-release ├── minor-20181227010225.json └── major-20181228010225.json ├── 1.1.0.json ├── 1.1.1.json ├── 1.1.2.json
The release process takes everything in
next-release and aggregates them all together in a single JSON file for that release (e.g
JSON file is a list of all the individual JSON files from
$ pip install semversioner
Bumping the version
In your local environment your will use the CLI to create the different changeset files that will be committed with your code. For example:
$ semversioner add-change --type patch --description "Fix security vulnerability with authentication."
Then, in your CI/CD tool you will need to release (generating automatically version number) and creating the the changelog file.
$ semversioner release
As a part of your CI/CD workflow, you will be able to generate the Changelog file with all changes.
$ semversioner changelog > CHANGELOG.md
You can filter the changelog by only showing changes for a specific version:
$ semversioner changelog --version "1.0.0"
Alternatively, you can use the following command to filter changes by the last released version:
$ semversioner changelog --version $(semversioner current-version)
Copyright (c) 2020 Raul Gomis. MIT licensed, see LICENSE file.
Made with ♥ by
Raul Gomis <https://twitter.com/rgomis>.
Note: version releases in the 0.x.y range may introduce breaking changes.
- minor: Improved performance by supporting multiple changeset files per second
- minor: Status command now sorts unreleased changes by type and description in order to display consistent results
- patch: Internal code refactor to improve code readability and maintanability
- minor: Add '--version' filter to the 'changelog' command to display the changelog only for a specific version
- minor: Add new 'status' command to display the state of the working directory and unreleased changes
- patch: Fix build and deployment configuration
- patch: Refactor method names and code for better code readability and testability
- minor: Deprecated .changes directory in favour of .semversioner directory
- patch: Internal refactor to improve code quality and test coverage
- patch: Fix installer error when referencing to LICENSE file
- minor: Enabled autocompletion by default
- patch: Improve docs for open source
- minor: Fail with error code when no changes are provided in the release command
- patch: Fix bug: add require module in setup.py
- patch: Fix packaging for LICENSE
- patch: Improve README.md documentation
- patch: Use jinja2 template engine internally to generate the changelog
- patch: Update docs
- patch: Fix README.md
- patch: Fix long description content type
- patch: Add README.md file
- patch: Fix code consistency
- patch: Fix packaging
- patch: Tag the repository when releasing
- patch: Fix tests and improve coverage
- minor: Initial version
Release history Release notifications | RSS feed
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
|Filename, size||File type||Python version||Upload date||Hashes|
|Filename, size semversioner-0.12.0-py2.py3-none-any.whl (9.3 kB)||File type Wheel||Python version py2.py3||Upload date||Hashes View|
|Filename, size semversioner-0.12.0.tar.gz (10.1 kB)||File type Source||Python version None||Upload date||Hashes View|
Hashes for semversioner-0.12.0-py2.py3-none-any.whl