Skip to content

Commit

Permalink
Merge pull request #18 from Nikronic/actions=doc
Browse files Browse the repository at this point in the history
fix using library version file instead of setup one (`VERSION`)
  • Loading branch information
Nikronic authored Sep 9, 2023
2 parents dce2c92 + c385622 commit 80fad9f
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions docs/source/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,10 @@
author = 'Nikan Doosti'

# The full version, including alpha/beta/rc tags
VERSION: dict = {}
with open('../../niklib/version.py', 'r') as version_file:
exec(version_file.read(), VERSION)
release = VERSION['VERSION']
version_file_path = '../../VERSION'
with open(version_file_path, 'r') as version_file:
package_version = version_file.read().strip()
release = package_version

# -- General configuration ---------------------------------------------------
# https://www.sphinx-doc.org/en/master/usage/configuration.html#general-configuration
Expand All @@ -45,6 +45,7 @@
'sphinx.ext.githubpages',
'sphinx.ext.autosectionlabel',
'sphinx_copybutton',
'myst_parser',
]

napoleon_use_ivar = True
Expand All @@ -59,7 +60,6 @@
# directories to ignore when looking for source files.
# This pattern also affects html_static_path and html_extra_path.
exclude_patterns = [
'niklib.version',
'_build'
]

Expand Down

0 comments on commit 80fad9f

Please sign in to comment.