On 26/02/16 11:16, Neil Jerram wrote: > I understand the semantic versioning algorithm for calculating a new > version. But what do I run, in a git repository, to do that calculation > for me, and output: > > - the new semantic version that would be used if I asked for a formal > release to PyPI > > - the corresponding Debian version > > - the corresponding RPM version. > > Thanks, > Neil
The following seems to work, but is it the best way? from pbr import version v = version.VersionInfo('networking-calico').semantic_version() print v.release_string() print v.brief_string() print v.debian_string() print v.rpm_string() Neil __________________________________________________________________________ OpenStack Development Mailing List (not for usage questions) Unsubscribe: openstack-dev-requ...@lists.openstack.org?subject:unsubscribe http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev