diff --git a/pylast/__init__.py b/pylast/__init__.py index 7c989dc..0b9755b 100644 --- a/pylast/__init__.py +++ b/pylast/__init__.py @@ -32,14 +32,15 @@ import tempfile import time import xml.dom -__version__ = "2.4.0.dev0" +from . import version + __author__ = "Amr Hassan, hugovk, Mice Pápai" __copyright__ = ( "Copyright (C) 2008-2010 Amr Hassan, 2013-2018 hugovk, " "2017 Mice Pápai" ) __license__ = "apache2" __email__ = "amr.hassan@gmail.com" - +__version__ = version.__version__ if sys.version_info.major == 2: import htmlentitydefs diff --git a/setup.py b/setup.py index fe1c40c..1c6d5cb 100755 --- a/setup.py +++ b/setup.py @@ -4,11 +4,16 @@ from setuptools import find_packages, setup with open("README.md") as f: long_description = f.read() +version_dict = {} +with open("pylast/version.py") as f: + exec(f.read(), version_dict) + version = version_dict['__version__'] + setup( name="pylast", long_description=long_description, long_description_content_type="text/markdown", - version="2.4.0.dev0", + version=version, author="Amr Hassan and Contributors", install_requires=["six"], tests_require=[