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
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 setuptools-version-command-1.2.tar.gz.
File metadata
- Download URL: setuptools-version-command-1.2.tar.gz
- Upload date:
- Size: 2.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
f12c4230344d266e2e42a1c645ba8be7136148b8bc5ca19b852b5c42f50eaf4d
|
|
| MD5 |
91655cd9aba32e58a0b8aa729c788f6e
|
|
| BLAKE2b-256 |
bca73085414c2b7632a64795db424aa62fa342dad758d12669fa74eeaa7c5aa6
|
File details
Details for the file setuptools_version_command-1.2-py2-none-any.whl.
File metadata
- Download URL: setuptools_version_command-1.2-py2-none-any.whl
- Upload date:
- Size: 4.5 kB
- Tags: Python 2
- Uploaded using Trusted Publishing? No
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
2d818bd817139573f7d51762eab839b9a29e16953f7edc9d3fd61922dcfbc7b2
|
|
| MD5 |
7091d46fce33eae0b6158bf0231be71c
|
|
| BLAKE2b-256 |
3ee4812ca362fef6aacdc2865a7d07d98d5b139cea81d4df6f27fa5b31d9a2ac
|