Packaging and Releasing TAU Commander¶
Versioning¶
TAU Commander follows semantic versioning (https://semver.org/). The version number is MAJOR.MINOR.PATCH.COMMIT where COMMIT is the number of commits since the last tag. E.g. version 1.3.0.5 is five unreleased commits after the version 1.3.0 release.
The VERSION
file is created automatically and shows the current version.
It might be out of date. It’s always a good idea to make clean
before
performing any task that depends on a version number.
setup.py¶
TAU Commander follows the Python Packaging Guide, the same resource that guides package deployment to the Python Package Index (PyPI). All tasks related to packaging and releasing TAU Commander are handled via the setup.py script in the project root directory. The script has many commands but most aren’t relevant to TAU Commander. The important ones are:
build: | Build everything needed for a new TAU Commander installation in the |
---|---|
build_sphinx: | Rebuild TAU Commander developer documentation (which you are currently reading) in the |
test: | Run all unit tests and pylint. |
release: | Generate distributable release packages in the git tag v1.3.1
make clean
python setup.py release --all
|
install: | Install a TAU Commander distribution. End users must NEVER use |
Use python setup.py <command> --help
to see command line options for each command.
[1] | It would be easy to publish TAU Commander to PyPI, but that may lead to users installing TAU Commander in their shared Python installation and cause problems when profiling Python applications via TAU Commander. |
[2] | Why not virtualenv? Because user’s are untrustworthy and do ... nonstandard ... things to their Python installations. Asserting that TAU Commander has it’s own, private Python installation simplifies installation and increases the chances that the installation will work on the first try. Also, we might not have network access at the user’s end so we can’t count on automatic dependency resolution. |