Moved the version string to the Salt module

This move will allow fetching the verison from multiple places such as
setup.py as well as the docs.
This commit is contained in:
Seth House 2011-09-25 00:30:36 -06:00
parent 80fa9baa9a
commit 02a3dab489
4 changed files with 11 additions and 4 deletions

View file

@ -9,6 +9,8 @@ sys.path.extend([
os.path.join(docs_basepath, '_ext'), # Sphinx extensions
])
from salt import __version__
# -- General configuration -----------------------------------------------------
# If your documentation needs a minimal Sphinx version, state it here.
@ -39,9 +41,9 @@ copyright = u'2011, Thomas S. Hatch'
# built documents.
#
# The short X.Y version.
version = '0.9.2'
version = __version__
# The full version, including alpha/beta/rc tags.
release = '0.9.2'
release = version
# The language for content autogenerated by Sphinx. Refer to documentation
# for a list of supported languages.

View file

@ -29,7 +29,7 @@ Release announcement:
Download
--------
The latest Salt is 0.9.2:
The latest Salt is |version|:
https://github.com/downloads/thatch45/salt/salt-0.9.2.tar.gz

View file

@ -1,6 +1,9 @@
'''
Make me some salt!
'''
__version_info__ = (0, 9, 2)
__version__ = '.'.join(map(str, __version_info__))
# Import python libs
import optparse
import os

View file

@ -11,8 +11,10 @@ from distutils.extension import Extension
from distutils.sysconfig import get_python_lib, PREFIX
from Cython.Distutils import build_ext
from salt import __version__
NAME = 'salt'
VER = '0.9.2'
VER = __version__
DESC = 'Portable, distrubuted, remote execution and configuration management system'
mod_path = os.path.join(get_python_lib(), 'salt/modules/')