[Distutils] Single version number
Barry Warsaw
barry at python.org
Fri Jul 10 15:24:24 CEST 2009
On Jul 10, 2009, at 8:58 AM, Marius Gedminas wrote:
> What do people use to avoid repeating the version number both in the
> setup.py as well as in application/library code, when the
> application/library wants to know its own version number?
>
> I've seen several options:
>
> 1) put __version__ = '4.2' in yourpackage/__init__.py, have setup.py
> do from yourpackage import __version__ and pass that to setup()
This is generally what I do and it seems to work pretty well for me.
I remember talking with Gary Poster about some problems with this,
related to our open source lazr packages, but I don't recall the
details.
-Barry
-------------- next part --------------
A non-text attachment was scrubbed...
Name: PGP.sig
Type: application/pgp-signature
Size: 832 bytes
Desc: This is a digitally signed message part
URL: <http://mail.python.org/pipermail/distutils-sig/attachments/20090710/2113260d/attachment.pgp>
More information about the Distutils-SIG
mailing list