Skip to content

Commit 7e2af3e

Browse files
authored
Merge pull request #607 from Remi-Gau/packaging
[ENH] package with hatchling and switch to pyproject.toml
2 parents d5fd9f7 + b7ddf6f commit 7e2af3e

File tree

8 files changed

+113
-2585
lines changed

8 files changed

+113
-2585
lines changed

.flake8

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
[flake8]
2+
max-line-length = 88
3+
extend-ignore = E203
4+
exclude = neurodocker/_version.py

.gitignore

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,9 @@
11
# MACOS related
22
.DS_Store
33

4+
# hatchling autogenerates it on install
5+
neurodocker/_version.py
6+
47
# Byte-compiled / optimized / DLL files
58
__pycache__/
69
*.py[cod]

neurodocker/__init__.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,10 +6,9 @@
66
from pathlib import Path
77

88
from neurodocker import reproenv # noqa: F401
9-
from neurodocker._version import get_versions
9+
from neurodocker._version import __version__
1010

11-
__version__ = get_versions()["version"]
12-
del get_versions
11+
__version__ = __version__
1312

1413
# Register neurodocker templates
1514
# TODO: remove registration from the `generate` cli. otherwise we register twice.

0 commit comments

Comments
 (0)