diff --git a/src/gnucash_web/__init__.py b/src/gnucash_web/__init__.py index e3ab833..a2c39cd 100644 --- a/src/gnucash_web/__init__.py +++ b/src/gnucash_web/__init__.py @@ -6,7 +6,7 @@ from flask.cli import FlaskGroup import click -from . import auth, book, commodities +from . import auth, book, commodities, __version__ from .utils import jinja as jinja_utils from .config import GnuCashWebConfig @@ -56,7 +56,7 @@ def create_app(test_config=None): app.jinja_env.filters['nth'] = jinja_utils.nth app.jinja_env.globals['is_authenticated'] = auth.is_authenticated - app.jinja_env.globals['pkg_version'] = metadata.version('gnucash_web') + app.jinja_env.globals['pkg_version'] = __version__.VERSION app.register_blueprint(auth.bp) app.register_blueprint(book.bp) diff --git a/src/gnucash_web/__version__.py b/src/gnucash_web/__version__.py new file mode 100644 index 0000000..1f6518e --- /dev/null +++ b/src/gnucash_web/__version__.py @@ -0,0 +1 @@ +VERSION = '0.1.0' diff --git a/src/setup.py b/src/setup.py index 0385647..5bed048 100755 --- a/src/setup.py +++ b/src/setup.py @@ -1,12 +1,13 @@ #!python from setuptools import setup, find_packages from os.path import exists +from . import __version__ readme = open('README.md') if exists('README.md') else open('../README.md') setup( name='GnuCash Web', - version='0.1.0', + version=__version__.VERSION, author='Joshua Bachmeier', author_email='joshua@bachmeier.cc', description='A simple, easy to use, mobile-friendly webinterface for GnuCash intended for self-hosting',