Skip to content

Commit 839686f

Browse files
authored
Merge pull request #50 from python-project-templates/tkp/jsexc
Explitly exclude js folder from wheel, use actions-ext node setup
2 parents 122ea92 + f7da89b commit 839686f

File tree

4 files changed

+6
-18
lines changed

4 files changed

+6
-18
lines changed

js/.github/workflows/build.yml.jinja

Lines changed: 2 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -40,16 +40,9 @@ jobs:
4040
with:
4141
version: {% raw %}${{ matrix.python-version }}{% endraw %}
4242

43-
- name: Use Node.js {% raw %}${{ matrix.node-version }}{% endraw %}
44-
uses: actions/setup-node@v4
43+
- uses: actions-ext/node/setup@main
4544
with:
46-
node-version: {% raw %}${{ matrix.node-version }}{% endraw %}
47-
48-
- name: Install pnpm
49-
uses: pnpm/action-setup@v4
50-
with:
51-
version: 9
52-
package_json_file: js/package.json
45+
version: 20.x
5346

5447
- name: Install dependencies
5548
run: make develop

js/pyproject.toml.jinja

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -111,6 +111,7 @@ exclude = [
111111

112112
[tool.hatch.build.targets.wheel]
113113
packages = ["{{module}}"]
114+
exclude = ["js"]
114115

115116
[tool.hatch.build.hooks.jupyter-builder]
116117
build-function = "hatch_jupyter_builder.npm_builder"

jupyter/.github/workflows/build.yml.jinja

Lines changed: 2 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -40,16 +40,9 @@ jobs:
4040
with:
4141
version: {% raw %}${{ matrix.python-version }}{% endraw %}
4242

43-
- name: Use Node.js {% raw %}${{ matrix.node-version }}{% endraw %}
44-
uses: actions/setup-node@v4
43+
- uses: actions-ext/node/setup@main
4544
with:
46-
node-version: {% raw %}${{ matrix.node-version }}{% endraw %}
47-
48-
- name: Install pnpm
49-
uses: pnpm/action-setup@v4
50-
with:
51-
version: 9
52-
package_json_file: js/package.json
45+
version: 20.x
5346

5447
- name: Install dependencies
5548
run: make develop

jupyter/pyproject.toml.jinja

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -118,6 +118,7 @@ exclude = [
118118
119119
[tool.hatch.build.targets.wheel]
120120
packages = ["{{module}}"]
121+
exclude = ["js"]
121122
122123
[tool.hatch.build.targets.wheel.shared-data]
123124
"{{module}}/labextension" = "share/jupyter/labextensions/{{module}}"

0 commit comments

Comments
 (0)