forked from Georg/pyacl
fix: 🐞 dynamic version system for older python and setuptools
Signed-off-by: Onuralp SEZER <thunderbirdtr@gmail.com>
This commit is contained in:
parent
d22b176521
commit
0ebe49fd37
@ -8,10 +8,4 @@ An English copy of the Licence is shipped in a file called LICENSE along with th
|
|||||||
You may obtain copies of the Licence in any of the official languages at https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12.
|
You may obtain copies of the Licence in any of the official languages at https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12.
|
||||||
"""
|
"""
|
||||||
|
|
||||||
import importlib.metadata as importlib_metadata
|
from .__version__ import __version__
|
||||||
|
|
||||||
try:
|
|
||||||
# This will read version from pyproject.toml
|
|
||||||
__version__ = importlib_metadata.version(__package__ or __name__)
|
|
||||||
except importlib_metadata.PackageNotFoundError:
|
|
||||||
__version__ = "development"
|
|
1
pyacl/__version__.py
Normal file
1
pyacl/__version__.py
Normal file
@ -0,0 +1 @@
|
|||||||
|
__version__ = "1.0.1"
|
@ -1,12 +1,12 @@
|
|||||||
[build-system]
|
[build-system]
|
||||||
requires = ["setuptools", "setuptools-scm", "wheel"]
|
requires = ["setuptools>=64", "setuptools-scm>=8", "wheel"]
|
||||||
build-backend = "setuptools.build_meta"
|
build-backend = "setuptools.build_meta"
|
||||||
|
|
||||||
|
|
||||||
[project]
|
[project]
|
||||||
name = 'pyacl'
|
name = 'pyacl'
|
||||||
description = 'High level abstractions over pylibacl'
|
description = 'High level abstractions over pylibacl'
|
||||||
version = '0.0.1'
|
dynamic = ["version", "readme"]
|
||||||
readme = "README.md"
|
|
||||||
authors = [
|
authors = [
|
||||||
{ name='Georg Pfuetzenreuter', email='georg+python@lysergic.dev' },
|
{ name='Georg Pfuetzenreuter', email='georg+python@lysergic.dev' },
|
||||||
]
|
]
|
||||||
@ -44,6 +44,10 @@ dev = [
|
|||||||
[tool.setuptools]
|
[tool.setuptools]
|
||||||
include-package-data = true # include non-python files in the package (default)
|
include-package-data = true # include non-python files in the package (default)
|
||||||
|
|
||||||
|
[tool.setuptools.dynamic]
|
||||||
|
version = {attr = "pyacl.__version__"}
|
||||||
|
readme = {file = ["README.md"]}
|
||||||
|
|
||||||
[tool.setuptools.packages.find]
|
[tool.setuptools.packages.find]
|
||||||
where = ["."]
|
where = ["."]
|
||||||
exclude = ["scripts", "scripts.*", "docs.*", "tests", "tests.*", "ruff.toml"]
|
exclude = ["scripts", "scripts.*", "docs.*", "tests", "tests.*", "ruff.toml"]
|
||||||
|
Loading…
Reference in New Issue
Block a user