Skip to content

Commit af05bea

Browse files
committed
Update precommit job
- Use output of get-node-version job to determine node version - Update actions/setup-python to recent version as v2 is EOLd
1 parent f97c64a commit af05bea

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

.github/workflows/test.yml

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -28,18 +28,19 @@ jobs:
2828
pre-commit:
2929
name: Run pre-commit
3030
runs-on: ubuntu-latest
31+
needs: get-node-version
3132
steps:
3233
- uses: actions/checkout@v5
3334
with:
3435
submodules: false
3536
- name: Setup Python 3.8
3637
id: setup-python
37-
uses: actions/setup-python@v2
38+
uses: actions/setup-python@v5
3839
with:
3940
python-version: "3.8"
4041
- uses: actions/setup-node@v5
4142
with:
42-
node-version: ${{ steps.get-node-version.outputs.node-version }}
43+
node-version: ${{ needs.get-node-version.outputs.node-version }}
4344
- uses: snok/install-poetry@v1
4445
with:
4546
version: 1.4.1
@@ -62,7 +63,7 @@ jobs:
6263
path: ~/.cache/pre-commit
6364
key: "pre-commit-${{ runner.os }}-\
6465
${{ steps.setup-python.outputs.python-version }}-\
65-
${{ steps.get-node-version.outputs.node-version }}-\
66+
${{ needs.get-node-version.outputs.node-version }}-\
6667
${{ hashFiles('.pre-commit-config.yaml') }}"
6768
- name: Run pre-commit
6869
run: poetry run pre-commit run --show-diff-on-failure --color=always --all-files

0 commit comments

Comments
 (0)