Skip to content

Commit

Permalink
Single-source project version
Browse files Browse the repository at this point in the history
  • Loading branch information
thvitt committed Jun 20, 2021
1 parent 5449670 commit cdde7d8
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
7 changes: 6 additions & 1 deletion delta/__init__.py
Expand Up @@ -7,8 +7,13 @@
Stylometrics in Python
"""

try:
import importlib.metadata as importlib_metadata
except ModuleNotFoundError: # < Python 3.8
import importlib_metadata

__title__ = 'delta'
__version__ = '2.0.0'
__version__ = importlib_metadata.version(__name__)
__author__ = 'Fotis Jannidis, Thorsten Vitt'

from warnings import warn
Expand Down
1 change: 1 addition & 0 deletions pyproject.toml
Expand Up @@ -19,6 +19,7 @@ regex = "^2021.4.4"
scikit-learn = "^0.24.2"
scikit-learn-extra = "^0.2.0"
joblib = "^1.0.1"
importlib-metadata = { version = "^1.0", python = "<3.8" }

[tool.poetry.dev-dependencies]
pytest = "^6.2.4"
Expand Down

0 comments on commit cdde7d8

Please sign in to comment.