summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorgrabner <pjg.github@ubergrabner.net>2014-04-15 21:53:00 -0400
committergrabner <pjg.github@ubergrabner.net>2014-04-15 21:53:00 -0400
commit0ba70364a2d8189682b9e4dc5d23519da040d109 (patch)
tree952a7003160068b75cb98232ea754709f5b0b267
parentba2298358ce4de151668cfe6540de9aa6b184b6d (diff)
downloadiniherit-0ba70364a2d8189682b9e4dc5d23519da040d109.tar.gz
extricated version into separate file
-rw-r--r--VERSION.txt1
-rwxr-xr-xsetup.py15
2 files changed, 8 insertions, 8 deletions
diff --git a/VERSION.txt b/VERSION.txt
new file mode 100644
index 0000000..1180819
--- /dev/null
+++ b/VERSION.txt
@@ -0,0 +1 @@
+0.1.7
diff --git a/setup.py b/setup.py
index da79891..e03eb99 100755
--- a/setup.py
+++ b/setup.py
@@ -11,14 +11,13 @@ import os, sys, setuptools
from setuptools import setup
# require python 2.7+
-assert(sys.version_info[0] > 2
- or sys.version_info[0] == 2
- and sys.version_info[1] >= 7)
+if sys.hexversion < 0x02070000:
+ raise RuntimeError('This package requires python 2.7 or better')
-here = os.path.abspath(os.path.dirname(__file__))
-def read(*parts):
- try: return open(os.path.join(here, *parts)).read()
- except: return ''
+heredir = os.path.abspath(os.path.dirname(__file__))
+def read(*parts, **kw):
+ try: return open(os.path.join(heredir, *parts)).read()
+ except: return kw.get('default', '')
test_requires = [
'nose >= 1.2.1',
@@ -48,7 +47,7 @@ classifiers = [
setup(
name = 'iniherit',
- version = '0.1.7',
+ version = read('VERSION.txt', default='0.0.1').strip(),
description = 'A ConfigParser subclass with file-specified inheritance.',
long_description = read('README.rst'),
classifiers = classifiers,