Automatic semantic versioning for python projects
Project description
# python-semantic-release
Automatic semantic versioning for python projects. This is an python implementation of the
[semantic-release][] for js by Stephan Bönnemann. If you find this topic interesting you should
check out his [talk from JSConf Budapest][semantic-release-talk].
[![Build status][build-badge]][last-build] ![PyPI version][pypi-badge]
## Install
```
pip install python-semantic-release
```
## Usage
The general idea is to have some sort of tag in commit messages that indicates certain types of changes.
If a commit message lack a tag it is ignored. Running release can be run locally or from a CI service.
```
Usage: semantic-release [OPTIONS] COMMAND
Options:
--major Force major version.
--minor Force minor version.
--patch Force patch version.
--noop No-operations mode, finds the new version number without changing it.
--post If used with the changelog command, the changelog will be posted to the release api.
--help Show this message and exit.
```
### Commands
* `version` - Create a new release. Will change the version, commit it and tag it.
* `publish` - Runs version before pushing to git and uploading to pypi.
* `changelog` - Generates the changelog for the next release.
### Running commands from setup.py
Add the following to your setup.py and you will be able to run `python setup.py <command>`
as you would `semantic-release <command>`.
```python
try:
from semantic_release import setup_hook
setup_hook(sys.argv)
except ImportError:
pass
```
### Configuration
Configuration belong in `semantic_release` section of the setup.cfg file in your project.
Details about configuration options can be found in [the configuration documentation][config-docs].
[last-build]: https://travis-ci.org/relekang/python-semantic-release
[build-badge]: https://travis-ci.org/relekang/python-semantic-release.svg?branch=master
[pypi-badge]: https://badge.fury.io/py/python-semantic-release.svg
[semantic-release-badge]: https://img.shields.io/badge/%20%20%F0%9F%93%A6%F0%9F%9A%80-semantic--release-e10079.svg
[gitter-badge]: https://badges.gitter.im/Join%20Chat.svg
[gitter-link]: https://gitter.im/relekang/python-semantic-release?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge
[semantic-release]: https://github.com/semantic-release/semantic-release
[semantic-release-talk]: https://www.youtube.com/watch?v=tc2UgG5L7WM
[config-docs]: http://python-semantic-release.readthedocs.org/en/latest/configuration.html
Automatic semantic versioning for python projects. This is an python implementation of the
[semantic-release][] for js by Stephan Bönnemann. If you find this topic interesting you should
check out his [talk from JSConf Budapest][semantic-release-talk].
[![Build status][build-badge]][last-build] ![PyPI version][pypi-badge]
## Install
```
pip install python-semantic-release
```
## Usage
The general idea is to have some sort of tag in commit messages that indicates certain types of changes.
If a commit message lack a tag it is ignored. Running release can be run locally or from a CI service.
```
Usage: semantic-release [OPTIONS] COMMAND
Options:
--major Force major version.
--minor Force minor version.
--patch Force patch version.
--noop No-operations mode, finds the new version number without changing it.
--post If used with the changelog command, the changelog will be posted to the release api.
--help Show this message and exit.
```
### Commands
* `version` - Create a new release. Will change the version, commit it and tag it.
* `publish` - Runs version before pushing to git and uploading to pypi.
* `changelog` - Generates the changelog for the next release.
### Running commands from setup.py
Add the following to your setup.py and you will be able to run `python setup.py <command>`
as you would `semantic-release <command>`.
```python
try:
from semantic_release import setup_hook
setup_hook(sys.argv)
except ImportError:
pass
```
### Configuration
Configuration belong in `semantic_release` section of the setup.cfg file in your project.
Details about configuration options can be found in [the configuration documentation][config-docs].
[last-build]: https://travis-ci.org/relekang/python-semantic-release
[build-badge]: https://travis-ci.org/relekang/python-semantic-release.svg?branch=master
[pypi-badge]: https://badge.fury.io/py/python-semantic-release.svg
[semantic-release-badge]: https://img.shields.io/badge/%20%20%F0%9F%93%A6%F0%9F%9A%80-semantic--release-e10079.svg
[gitter-badge]: https://badges.gitter.im/Join%20Chat.svg
[gitter-link]: https://gitter.im/relekang/python-semantic-release?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge
[semantic-release]: https://github.com/semantic-release/semantic-release
[semantic-release-talk]: https://www.youtube.com/watch?v=tc2UgG5L7WM
[config-docs]: http://python-semantic-release.readthedocs.org/en/latest/configuration.html
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distributions
Close
Hashes for python-semantic-release-3.3.3.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 73009aa53c1edd0c65ea717826f13d06906db7886e98bf3a1204579d6aa69f43 |
|
MD5 | fc291ed6d647db01e7b863d06019ddc0 |
|
BLAKE2b-256 | 414acc2f0d65dd4612b1be5bf5bbbc5b7d0d757a37c67538430821665615752a |
Close
Hashes for python_semantic_release-3.3.3-py2.py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 89eb8e09a436a85512888cfac0451019691b44697c82673e9d2cdbd5b268575e |
|
MD5 | 9cae913328afd7ecfabf27e5324b88ed |
|
BLAKE2b-256 | 8d53b3ceccc7703b666e2d73b52ca40660e4e455cacdb751a6178c590d808f37 |
Close
Hashes for python_semantic_release-3.3.3-py2.7.egg
Algorithm | Hash digest | |
---|---|---|
SHA256 | 7225b96684914e6564ab3e1bc4541a0a37bbde84ba46f0cab295968708600cb5 |
|
MD5 | 0bc39ed094734bcd41883efce128ffb5 |
|
BLAKE2b-256 | 5f896d7279ca10bcb4fb24040e853178415b6b2365edf9941fb7126292a81994 |