]> git.phdru.name Git - ppu.git/commitdiff
Build: Use module returned by imp.load_source() directly
authorOleg Broytman <phd@phdru.name>
Sun, 4 Feb 2018 06:22:51 +0000 (09:22 +0300)
committerOleg Broytman <phd@phdru.name>
Sun, 4 Feb 2018 06:22:51 +0000 (09:22 +0300)
setup.py

index de4095a971b3cd4e2c599f22cd77a083669b34c9..c4d2bfc41d95b9e13230247ab92712d6a0def509 100755 (executable)
--- a/setup.py
+++ b/setup.py
@@ -15,11 +15,10 @@ if is_setuptools:
     kw['python_requires'] = '>=2.7, !=3.0.*, !=3.1.*, !=3.2.*'
 
 versionpath = join(abspath(dirname(__file__)), "ppu", "__version__.py")
-load_source("ppu_version", versionpath)
-from ppu_version import __version__  # noqa: ignore flake8 E402
+ppu_version = load_source("ppu_version", versionpath)
 
 setup(name='ppu',
-      version=__version__,
+      version=ppu_version.__version__,
       description='Broytman Portable Python Utilities',
       long_description=open('README.rst', 'rU').read(),
       author='Oleg Broytman',