Skip to content

Commit 3200b3c

Browse files
committed
more repo setup
1 parent 3a23fd4 commit 3200b3c

File tree

5 files changed

+14
-6
lines changed

5 files changed

+14
-6
lines changed

pixi.lock

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

pyproject.toml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,12 +9,15 @@ authors = [
99
name = "pint-array"
1010
description = "Pint quantities with array API standard arrays."
1111
readme = "README.md"
12-
version = "0.0.1.dev0"
12+
dynamic = ["version"]
1313
requires-python = ">=3.9"
1414

1515
[project.urls]
1616
Homepage = "https://github.com/lucascolley/pint-array"
1717

18+
[tool.hatch]
19+
version.path = "src/pint_array/__init__.py"
20+
1821
[tool.pixi.project]
1922
channels = ["conda-forge"]
2023
platforms = ["osx-arm64"]

src/pint_array/__init__.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,8 @@
1414
from pint.facets.plain import MagnitudeT, PlainQuantity
1515
from pint import Quantity
1616

17-
__all__ = ["pint_namespace", "ArrayUnitQuantity"]
17+
__version__ = "0.0.1.dev0"
18+
__all__ = ["pint_namespace", "__version__"]
1819

1920

2021
def pint_namespace(xp):

tests/test_pint_array.py

Lines changed: 0 additions & 3 deletions
This file was deleted.

tests/test_version.py

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
import importlib.metadata
2+
3+
import pint_array
4+
5+
6+
def test_version():
7+
assert importlib.metadata.version("pint_array") == pint_array.__version__

0 commit comments

Comments
 (0)