Adds a command to dynamically get the version from the VCS of choice
Project description
setuptools-version-command -- get version from VCS
Instead of hardcoding the version in setup.py like this:
setup(
name='some-dist-name',
version='1.0',
...)
This package allows specifying a VCS command like this:
setup(
name='some-dist-name',
version_command='git describe')
Which will then update the version into some-dist-name.egg-info/version.txt,
so that the version can also be found if setup.py is being run from a sdist
or something.
When it can find the version from either some-dist-name.egg-info/version.txt
or the output of the version_command, it will update the version key that is
normally used for the version, such as what's used in the sdist filename and
so on.
SETUP KEYWORDS
version_command: the command to execute to obtain a version.
example: 'git describe'
version_command_pep440: whether to make output compliant with PEP 440
(instead of the other way around...)
valid values:
'git' or
'git-local' : transform '1.2-3-abc1234' to '1.2+git-3-abc1234'
'git-dev' : transform '1.2-3-abc1234' to '1.2.dev3'
default is None, which means do nothing.
INSTALLATION
To use it, just do this:
pip install setuptools-version-command
With the pip of the global python.
Instead of hardcoding the version in setup.py like this:
setup(
name='some-dist-name',
version='1.0',
...)
This package allows specifying a VCS command like this:
setup(
name='some-dist-name',
version_command='git describe')
Which will then update the version into some-dist-name.egg-info/version.txt,
so that the version can also be found if setup.py is being run from a sdist
or something.
When it can find the version from either some-dist-name.egg-info/version.txt
or the output of the version_command, it will update the version key that is
normally used for the version, such as what's used in the sdist filename and
so on.
SETUP KEYWORDS
version_command: the command to execute to obtain a version.
example: 'git describe'
version_command_pep440: whether to make output compliant with PEP 440
(instead of the other way around...)
valid values:
'git' or
'git-local' : transform '1.2-3-abc1234' to '1.2+git-3-abc1234'
'git-dev' : transform '1.2-3-abc1234' to '1.2.dev3'
default is None, which means do nothing.
INSTALLATION
To use it, just do this:
pip install setuptools-version-command
With the pip of the global python.
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 Distribution
Close
Hashes for setuptools-version-command-1.1.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 33e0e96763f9269e553a9ba3a6ff11a6ef5774ea8c8ba09805bac6f1277f9fd2 |
|
MD5 | 03a4e386d1c0687a8b43bd11fd492f64 |
|
BLAKE2b-256 | 61e52f9334cf45d62e04a69458c715978c3a66478c5406d03b03d2003230e17a |
Close
Hashes for setuptools_version_command-1.1-py2-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 5108ff1da1f5ada0b30bf7bae880f85f0430e0bd664882e253c4a86c69ed2bf1 |
|
MD5 | 567ec413c7cc6ff7e7a78c69fcd2cc86 |
|
BLAKE2b-256 | ac455b9abc8e6ba3855d304384d53908ae005abbca9c8345189bca683054e18d |