aboutsummaryrefslogtreecommitdiffstats
path: root/setup.py
diff options
context:
space:
mode:
authorMaximilian Hils <git@maximilianhils.com>2016-12-11 17:50:46 +0100
committerMaximilian Hils <git@maximilianhils.com>2016-12-11 17:50:46 +0100
commit00ae4d3f6e993b06b808cf08e0441fcbacff4f16 (patch)
tree691fee9169777e9e956725b3f75daa0818ba8c6a /setup.py
parent782c66eac23c0f287c569e5dc6b9c635b2e32afe (diff)
downloadmitmproxy-00ae4d3f6e993b06b808cf08e0441fcbacff4f16.tar.gz
mitmproxy-00ae4d3f6e993b06b808cf08e0441fcbacff4f16.tar.bz2
mitmproxy-00ae4d3f6e993b06b808cf08e0441fcbacff4f16.zip
fix version sourcing in setup.py
Diffstat (limited to 'setup.py')
-rw-r--r--setup.py10
1 files changed, 6 insertions, 4 deletions
diff --git a/setup.py b/setup.py
index 4f4d5c7d..e8aea2d6 100644
--- a/setup.py
+++ b/setup.py
@@ -1,8 +1,8 @@
-from setuptools import setup, find_packages
-from codecs import open
import os
+import runpy
+from codecs import open
-from mitmproxy import version
+from setuptools import setup, find_packages
# Based on https://github.com/pypa/sampleproject/blob/master/setup.py
# and https://python-packaging-user-guide.readthedocs.org/
@@ -12,9 +12,11 @@ here = os.path.abspath(os.path.dirname(__file__))
with open(os.path.join(here, 'README.rst'), encoding='utf-8') as f:
long_description = f.read()
+VERSION = runpy.run_path(os.path.join(here, "mitmproxy", "version.py"))["VERSION"]
+
setup(
name="mitmproxy",
- version=version.VERSION,
+ version=VERSION,
description="An interactive, SSL-capable, man-in-the-middle HTTP proxy for penetration testers and software developers.",
long_description=long_description,
url="http://mitmproxy.org",