forked from simplegeo/python-simplegeo
-
Notifications
You must be signed in to change notification settings - Fork 1
/
setup.py
33 lines (31 loc) · 1.08 KB
/
setup.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
#!/usr/bin/env python
#from distutils.core import setup
from setuptools import setup, find_packages
import os, re
PKG='simplegeo'
VERSIONFILE = os.path.join(PKG, '_version.py')
verstr = "unknown"
try:
verstrline = open(VERSIONFILE, "rt").read()
except EnvironmentError:
pass # Okay, there is no version file.
else:
VSRE = r"^verstr = ['\"]([^'\"]*)['\"]"
mo = re.search(VSRE, verstrline, re.M)
if mo:
verstr = mo.group(1)
else:
print "unable to find version in %s" % (VERSIONFILE,)
raise RuntimeError("if %s.py exists, it must be well-formed" % (VERSIONFILE,))
setup(name=PKG,
version=verstr,
description="Library for interfacing with SimpleGeo's API",
author="Joe Stump",
author_email="joe@simplegeo.com",
url="http://github.com/simplegeo/python-simplegeo",
packages = find_packages(),
license = "MIT License",
install_requires=['httplib2>=0.6.0', 'oauth2>=1.1.3', 'simplejson>=2.0.9'],
keywords="simplegeo",
zip_safe = True,
tests_require=['nose', 'coverage', 'python-geohash>=0.2', 'mock'])