4 Summary: generate a version number from darcs history
5 Home-page: http://tahoe-lafs.org/trac/darcsver
6 Author: Zooko O'Whielacronx
7 Author-email: zooko@zooko.com
9 Description: darcsver - generate version numbers from darcs revision control history
10 =======================================================================
15 Create files containing version numbers, based upon the latest darcs
18 If your source tree is coming from darcs (i.e. it is in a darcs
19 repository), this tool will determine the most recent release tag,
20 count the patches that have been applied since then, and compute a
21 version number to be written into _version.py (and optionally other
22 version files). This version number will be available by doing:
24 from your_package_name import __version__
26 Source trees that do not come from darcs (e.g. release tarballs, nightly
27 tarballs) and are not within a darcs repository should instead, come with a
28 _version.py that was generated before the tarball was produced. In this case,
29 this tool will quietly exit without modifying the existing _version.py .
31 'release tags' are tags in the source repository that match the following
34 ^your_package_name-(\d+)(\.(\d+)(\.(\d+))?)?((a|b|c|rc)(\d+))?
44 Alternative manual installation:
46 tar -zxvf darcsver-X.Y.Z.tar.gz
48 python setup.py install
50 Where X.Y.Z is a version number.
52 Alternative to make a specific package use darcsver without installing
53 darcsver into the system:
55 Put "setup_requires=['darcsver']" in the call to setup() in the
56 package's setup.py file.
62 There are two ways to use this: the command-line tool and the
65 To use the command-line tool, execute it as:
67 darcsver $PACKAGE_NAME $PATH_TO_VERSION_PY
70 To use the setuptools plugin (which enables you to write "./setup.py
71 darcsver" and which cleverly figures out where the _version.py file
72 ought to go), you must first package your python module with
73 `setup.py` and use setuptools.
75 The former is well documented in the distutils manual:
77 http://docs.python.org/dist/dist.html
79 To use setuptools instead of distutils, just edit `setup.py` and
82 from distutils.core import setup
86 from setuptools import setup
92 How to distribute Python modules with Distutils:
94 http://docs.python.org/dist/dist.html
97 Setuptools complete manual:
99 http://peak.telecommunity.com/DevCenter/setuptools
102 Thanks to Yannick Gingras for providing the prototype for this
105 Keywords: distutils setuptools plugin setup darcs
107 Classifier: Framework :: Setuptools Plugin
108 Classifier: Development Status :: 5 - Production/Stable
109 Classifier: License :: OSI Approved :: BSD License
110 Classifier: License :: DFSG approved
111 Classifier: Intended Audience :: Developers
112 Classifier: Operating System :: OS Independent
113 Classifier: Natural Language :: English
114 Classifier: Programming Language :: Python
115 Classifier: Programming Language :: Python :: 2
116 Classifier: Programming Language :: Python :: 2.4
117 Classifier: Programming Language :: Python :: 2.5
118 Classifier: Programming Language :: Python :: 2.6
119 Classifier: Programming Language :: Python :: 2.7
120 Classifier: Topic :: Utilities
121 Classifier: Topic :: Software Development :: Libraries