Skip to content

Commit

Permalink
Automatic versioning using git describe
Browse files Browse the repository at this point in the history
Use ~= dependencies
  • Loading branch information
lhupfeldt committed Nov 28, 2015
1 parent e8c90e8 commit 48fa4b1
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 15 deletions.
File renamed without changes.
33 changes: 18 additions & 15 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,48 +4,47 @@


PROJECT_ROOT, _ = os.path.split(__file__)
SHORT_VERSION = '0.9'
LONG_VERSION = SHORT_VERSION + '.0'
PROJECT_NAME = 'jenkinsflow'
COPYRIGHT = u"Copyright (c) 2012 - 2015 Lars Hupfeldt Nielsen, Hupfeldt IT"
PROJECT_AUTHORS = u"Lars Hupfeldt Nielsen"
PROJECT_EMAILS = 'lhn@hupfeldtit.dk'
PROJECT_URL = "https://github.com/lhupfeldt/jenkinsflow"
SHORT_DESCRIPTION = 'Python API with high level build flow constructs (parallel/serial) for Jenkins (and Hudson).'
LONG_DESCRIPTION = open(os.path.join(PROJECT_ROOT, "README.md")).read()
LONG_DESCRIPTION = open(os.path.join(PROJECT_ROOT, "README.txt")).read()


if sys.version_info.major < 3:
py_version_requires = ['enum34', 'subprocess32']
py_version_test_require = ['proxytypes']
else:
py_version_requires = []
py_version_test_require = ['objproxies>=0.9.4']
py_version_test_require = ['objproxies~=0.9.4']


if __name__ == "__main__":
setup(
name=PROJECT_NAME.lower(),
version=LONG_VERSION,
version_command=('git describe', 'pep440-git'),
author=PROJECT_AUTHORS,
author_email=PROJECT_EMAILS,
packages=['jenkinsflow', 'jenkinsflow.cli'],
package_dir={'jenkinsflow':'.', 'jenkinsflow.cli': 'cli'},
zip_safe=True,
include_package_data=False,
install_requires=['requests>=2.7.0',
'atomicfile>=1.0',
'psutil>=3.2.1',
'setproctitle>=1.1.9',
'click>=5.1',
'tenjin>=1.1.1',
'bottle>=0.12.8'] + py_version_requires,
install_requires=['requests~=2.7.0',
'atomicfile~=1.0',
'psutil~=3.2.1',
'setproctitle~=1.1.9',
'click~=5.1',
'tenjin~=1.1.1',
'bottle~=0.12.8'] + py_version_requires,
setup_requires='setuptools-version-command~=2.2',
test_suite='test',
test_loader='test.test:TestLoader',
tests_require=['pytest>=2.8.2', 'pytest-cov>=2.1.0', 'pytest-instafail>=0.3.0', 'pytest-xdist>=1.13.1',
'click>=5.1', 'tenjin>=1.1.1', 'bottle>=0.12.8',
tests_require=['pytest~=2.8.2', 'pytest-cov~=2.1.0', 'pytest-instafail~=0.3.0', 'pytest-xdist~=1.13.1',
'click~=5.1', 'tenjin~=1.1.1', 'bottle~=0.12.8',
# The test also tests creation of the documentation
'sphinx>=1.3.1', 'sphinxcontrib-programoutput'] + py_version_test_require,
'sphinx~=1.3.1', 'sphinxcontrib-programoutput'] + py_version_test_require,
url=PROJECT_URL,
description=SHORT_DESCRIPTION,
long_description=LONG_DESCRIPTION,
Expand All @@ -58,10 +57,14 @@
'Natural Language :: English',
'Operating System :: OS Independent',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3.4',
'Programming Language :: Python :: 3.5',
'Topic :: Software Development :: Testing',
],
entry_points='''
[console_scripts]
jenkinsflow=jenkinsflow.cli.cli:cli
''',
)


0 comments on commit 48fa4b1

Please sign in to comment.