Skip to content

Commit

Permalink
Fix dynamic versioning
Browse files Browse the repository at this point in the history
Signed-off-by: Aryan Roy <[email protected]>
  • Loading branch information
aryan26roy committed Nov 5, 2024
1 parent c57283e commit bfaeb94
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 5 deletions.
7 changes: 5 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -105,5 +105,8 @@ venv.bak/
.mypy_cache/
/formulate/version.py

#DS_STORE
**/.DS_Store
# DS_STORE
**/.DS_Store

# Versioning
**/_version.py
6 changes: 4 additions & 2 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[build-system]
requires = ["hatchling"]
requires = ["hatchling", "hatch-vcs"]
build-backend = "hatchling.build"
[project]
name = "formulate"
Expand Down Expand Up @@ -54,8 +54,10 @@ Homepage = "https://github.com/Scikit-HEP/formulate"
"Bug Tracker" = "https://github.com/Scikit-HEP/formulate/issues"
Discussions = "https://github.com/Scikit-HEP/formulate/discussions"
Changelog = "https://github.com/Scikit-HEP/formulate/releases"

[tool.hatch]
version.path = "src/formulate/__init__.py"
version.source = "vcs"
build.hooks.vcs.version-file = "src/formulate/_version.py"
envs.default.dependencies = [
"pytest",
"pytest-cov",
Expand Down
7 changes: 6 additions & 1 deletion src/formulate/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,13 @@

from . import toast

from .version import __version__
from ._version import __version__

# print("======================")
# print(__version__.__repr__())
# print("======================")

# __all__ = ("__version__",)



Expand Down

0 comments on commit bfaeb94

Please sign in to comment.