diff --git a/setup.py b/setup.py index 78ab795..302dd88 100644 --- a/setup.py +++ b/setup.py @@ -3,9 +3,15 @@ with open("README.md", "r") as fh: long_description = fh.read() +with open("src/NERDA/about.py") as f: + v = f.read() + for l in v.split("\n"): + if l.startswith("__version__"): + __version__ = l.split('"')[-2] + setuptools.setup( name="NERDA", - version="1.0.0", + version=__version__, author="Lars Kjeldgaard, Lukas Christian Nielsen", author_email="lars.kjeldgaard@eb.dk", description="A Framework for Finetuning Transformers for Named-Entity Recognition", diff --git a/src/NERDA/__init__.py b/src/NERDA/__init__.py index 2d7ded4..ef19635 100644 --- a/src/NERDA/__init__.py +++ b/src/NERDA/__init__.py @@ -1 +1,2 @@ -import NERDA \ No newline at end of file +import NERDA +from .about import __version__, __title__ diff --git a/src/NERDA/about.py b/src/NERDA/about.py new file mode 100644 index 0000000..96e56d3 --- /dev/null +++ b/src/NERDA/about.py @@ -0,0 +1,2 @@ +__title__ = "NERDA" +__version__ = "1.0.1" # the ONLY source of version ID