Skip to content

Commit 8054b05

Browse files
committed
get workflows to run
1 parent e025f05 commit 8054b05

File tree

5 files changed

+20
-17
lines changed

5 files changed

+20
-17
lines changed

Diff for: .github/workflows/.hatch-run.yml

+2-2
Original file line numberDiff line numberDiff line change
@@ -46,8 +46,8 @@ jobs:
4646
with:
4747
python-version: ${{ matrix.python-version }}
4848
- name: Install Python Dependencies
49-
run: pip install -r requirements/nox-deps.txt
50-
- name: Run Sessions
49+
run: pip install hatch
50+
- name: Run Scripts
5151
env:
5252
NODE_AUTH_TOKEN: ${{ secrets.node-auth-token }}
5353
PYPI_USERNAME: ${{ secrets.pypi-username }}

Diff for: .github/workflows/publish.yml

+2-2
Original file line numberDiff line numberDiff line change
@@ -9,10 +9,10 @@ on:
99

1010
jobs:
1111
publish:
12-
uses: ./.github/workflows/.nox-session.yml
12+
uses: ./.github/workflows/.hatch-run.yml
1313
with:
1414
job-name: "publish"
15-
nox-args: "-s publish"
15+
hatch-run: "publish"
1616
secrets:
1717
node-auth-token: ${{ secrets.NODE_AUTH_TOKEN }}
1818
pypi-username: ${{ secrets.PYPI_USERNAME }}

Diff for: .github/workflows/test.yml

+7-9
Original file line numberDiff line numberDiff line change
@@ -15,23 +15,21 @@ jobs:
1515
uses: ./.github/workflows/.hatch-run.yml
1616
with:
1717
job-name: "python-{0}"
18-
hatch-run: "-t check-python"
19-
nox-session-args: "--pytest --maxfail=3 --reruns 3"
18+
hatch-run: "check-py"
2019
python-environments:
21-
uses: ./.github/workflows/.nox-session.yml
20+
uses: ./.github/workflows/.hatch-run.yml
2221
with:
2322
job-name: "python-{0} {1}"
24-
nox-args: "-s check-python-tests"
25-
nox-session-args: "--no-cov --pytest --maxfail=3 --reruns 3"
23+
hatch-run: "check-py --no-cov"
2624
runs-on-array: '["ubuntu-latest", "macos-latest", "windows-latest"]'
2725
python-version-array: '["3.9", "3.10", "3.11"]'
2826
docs:
29-
uses: ./.github/workflows/.nox-session.yml
27+
uses: ./.github/workflows/.hatch-run.yml
3028
with:
3129
job-name: "python-{0}"
32-
nox-args: "-s check-docs"
30+
hatch-run: "test-docs"
3331
javascript:
34-
uses: ./.github/workflows/.nox-session.yml
32+
uses: ./.github/workflows/.hatch-run.yml
3533
with:
3634
job-name: "{1}"
37-
nox-args: "-t check-javascript"
35+
hatch-run: "test-js lint-js"

Diff for: pyproject.toml

+4-4
Original file line numberDiff line numberDiff line change
@@ -14,15 +14,15 @@ post-install-commands = ["invoke env"]
1414
[tool.hatch.envs.default.scripts]
1515
publish = "invoke publish {args}"
1616

17-
checks = ["lint", "test"]
18-
lint = ["lint-py {args}", "lint-js {args}"]
19-
test = ["test-py", "test-js"]
17+
check-py = "invoke test-py {args} lint-py"
18+
check-js = "invoke test-js lint-js"
2019

2120
lint-py = "invoke lint-py {args}"
2221
lint-js = "invoke lint-js {args}"
2322

2423
test-py = "invoke test-py {args}"
25-
test-js = "invoke test-js {args}"
24+
test-js = "invoke test-js"
25+
test-docs = "invoke test-docs"
2626

2727
# --- Black ----------------------------------------------------------------------------
2828

Diff for: tasks.py

+5
Original file line numberDiff line numberDiff line change
@@ -94,6 +94,11 @@ def test_js(context: Context):
9494
in_js(context, "npm run check:tests")
9595

9696

97+
@task
98+
def test_docs(context: Context):
99+
raise Exit("Not implemented")
100+
101+
97102
@task
98103
def publish(context: Context, dry_run: str = ""):
99104
"""Publish packages that have been tagged for release in the current commit

0 commit comments

Comments
 (0)