Skip to content

Commit dcc1033

Browse files
committed
Move from explicit includes/excludes list to packages, tweak some commands
1 parent 32d9945 commit dcc1033

7 files changed

+13
-86
lines changed

js/Makefile.jinja

+1-4
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ format: fix
5555
################
5656
# Other Checks #
5757
################
58-
.PHONY: check-manifest checks check annotate
58+
.PHONY: check-manifest checks check
5959

6060
check-manifest: ## check python sdist manifest with check-manifest
6161
check-manifest -v
@@ -65,9 +65,6 @@ checks: check-manifest
6565
# alias
6666
check: checks
6767

68-
annotate: ## run python type annotation checks with mypy
69-
python -m mypy ./{{module}}
70-
7168
#########
7269
# TESTS #
7370
#########

js/pyproject.toml.jinja

+3-23
Original file line numberDiff line numberDiff line change
@@ -102,34 +102,14 @@ artifacts = [
102102
src = "/"
103103

104104
[tool.hatch.build.targets.sdist]
105-
include = [
106-
"/{{module}}",
107-
"/js",
108-
"LICENSE",
109-
"README.md",
110-
]
105+
packages = ["{{module}}", "js"]
111106
exclude = [
112-
".copier-answers.yml",
113-
"/.github",
114-
"/.gitattributes",
115-
"/.gitignore",
116-
"/docs",
107+
"/js/dist",
117108
"/js/node_modules",
118109
]
119110

120111
[tool.hatch.build.targets.wheel]
121-
include = [
122-
"/{{module}}",
123-
]
124-
exclude = [
125-
".copier-answers.yml",
126-
"/.github",
127-
"/.gitattributes",
128-
"/.gitignore",
129-
"/pyproject.toml",
130-
"/docs",
131-
"/js/node_modules",
132-
]
112+
packages = ["{{module}}"]
133113

134114
[tool.hatch.build.hooks.jupyter-builder]
135115
build-function = "hatch_jupyter_builder.npm_builder"

jupyter/Makefile.jinja

+1-4
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ format: fix
5555
################
5656
# Other Checks #
5757
################
58-
.PHONY: check-manifest checks check annotate
58+
.PHONY: check-manifest checks check
5959

6060
check-manifest: ## check python sdist manifest with check-manifest
6161
check-manifest -v
@@ -65,9 +65,6 @@ checks: check-manifest
6565
# alias
6666
check: checks
6767

68-
annotate: ## run python type annotation checks with mypy
69-
python -m mypy ./{{module}}
70-
7168
#########
7269
# TESTS #
7370
#########

jupyter/pyproject.toml.jinja

+3-23
Original file line numberDiff line numberDiff line change
@@ -105,34 +105,14 @@ artifacts = [
105105
src = "/"
106106
107107
[tool.hatch.build.targets.sdist]
108-
include = [
109-
"/{{module}}",
110-
"/js",
111-
"LICENSE",
112-
"README.md",
113-
]
108+
packages = ["{{module}}", "js"]
114109
exclude = [
115-
".copier-answers.yml",
116-
"/.github",
117-
"/.gitattributes",
118-
"/.gitignore",
110+
"/js/dist",
119111
"/js/node_modules",
120-
"/docs",
121112
]
122113
123114
[tool.hatch.build.targets.wheel]
124-
include = [
125-
"/{{module}}",
126-
]
127-
exclude = [
128-
".copier-answers.yml",
129-
"/.github",
130-
"/.gitattributes",
131-
"/.gitignore",
132-
"/pyproject.toml",
133-
"/docs",
134-
"/js/node_modules",
135-
]
115+
packages = ["{{module}}"]
136116
137117
[tool.hatch.build.targets.wheel.shared-data]
138118
"{{module}}/labextension" = "share/jupyter/labextensions/{{module}}"

python/Makefile.jinja

+2-5
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ develop: ## install dependencies and build library
77
python -m pip install -e .[develop]
88

99
build: ## build the python library
10-
python setup.py build build_ext --inplace
10+
python -m build -n
1111

1212
install: ## install library
1313
python -m pip install .
@@ -34,7 +34,7 @@ format: fix
3434
################
3535
# Other Checks #
3636
################
37-
.PHONY: check-manifest checks check annotate
37+
.PHONY: check-manifest checks check
3838

3939
check-manifest: ## check python sdist manifest with check-manifest
4040
check-manifest -v
@@ -44,9 +44,6 @@ checks: check-manifest
4444
# Alias
4545
check: checks
4646

47-
annotate: ## run python type annotation checks with mypy
48-
python -m mypy ./{{module}}
49-
5047
#########
5148
# TESTS #
5249
#########

python/pyproject.toml.jinja

+2-23
Original file line numberDiff line numberDiff line change
@@ -88,31 +88,10 @@ artifacts = []
8888
src = "/"
8989

9090
[tool.hatch.build.targets.sdist]
91-
include = [
92-
"/{{module}}",
93-
"LICENSE",
94-
"README.md",
95-
]
96-
exclude = [
97-
".copier-answers.yml",
98-
"/.github",
99-
"/.gitattributes",
100-
"/.gitignore",
101-
"/docs",
102-
]
91+
packages = ["{{module}}"]
10392

10493
[tool.hatch.build.targets.wheel]
105-
include = [
106-
"/{{module}}",
107-
]
108-
exclude = [
109-
".copier-answers.yml",
110-
"/.github",
111-
"/.gitattributes",
112-
"/.gitignore",
113-
"/pyproject.toml",
114-
"/docs",
115-
]
94+
packages = ["{{module}}"]
11695

11796
[tool.hatch.build.targets.wheel.shared-data]
11897

rust/Makefile.jinja

+1-4
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ format: fix
6565
################
6666
# Other Checks #
6767
################
68-
.PHONY: check-manifest checks check annotate
68+
.PHONY: check-manifest checks check
6969

7070
check-manifest: ## check python sdist manifest with check-manifest
7171
check-manifest -v
@@ -75,9 +75,6 @@ checks: check-manifest
7575
# alias
7676
check: checks
7777

78-
annotate: ## run python type annotation checks with mypy
79-
python -m mypy ./{{module}}
80-
8178
#########
8279
# TESTS #
8380
#########

0 commit comments

Comments
 (0)