File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -21,6 +21,24 @@ concurrency:
2121 group : ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
2222 cancel-in-progress : true
2323jobs :
24+ pre-commit :
25+ runs-on : ubuntu-24.04
26+ permissions :
27+ contents : read
28+ steps :
29+ - uses : actions/checkout@v6
30+ - uses : actions/setup-python@v6
31+ # code mostly taken from https://github.com/pre-commit/action/blob/main/action.yml
32+ - run : python -m pip install pre-commit==4.5.1
33+ shell : bash
34+ - run : python -m pip freeze --local
35+ shell : bash
36+ - uses : actions/cache@v5
37+ with :
38+ path : ~/.cache/pre-commit
39+ key : pre-commit-3|${{ env.pythonLocation }}|${{ hashFiles('.pre-commit-config.yaml') }}
40+ - run : pre-commit run --show-diff-on-failure --color=always --all-files
41+ shell : bash
2442 build :
2543 strategy :
2644 matrix :
3452 runner : ubuntu-24.04-arm
3553 name : ${{ matrix.name }}
3654 runs-on : ${{ matrix.runner }}
55+ needs : pre-commit
3756 permissions :
3857 contents : read
3958 packages : write
5776 runCmd : |
5877 set -eux pipefail
5978
60- # Check
61- pre-commit run --show-diff-on-failure --color=always --all-files || exit 1
62-
6379 # Create builder for multi-arch builds
6480 ./scripts/create_builder.sh
6581
Original file line number Diff line number Diff line change 1717 tags :
1818 - v[0-9]+.[0-9]+.[0-9]+
1919jobs :
20+ pre-commit :
21+ runs-on : ubuntu-24.04
22+ permissions :
23+ contents : read
24+ steps :
25+ - uses : actions/checkout@v6
26+ - uses : actions/setup-python@v6
27+ # code mostly taken from https://github.com/pre-commit/action/blob/main/action.yml
28+ - run : python -m pip install pre-commit==4.5.1
29+ shell : bash
30+ - run : python -m pip freeze --local
31+ shell : bash
32+ - uses : actions/cache@v5
33+ with :
34+ path : ~/.cache/pre-commit
35+ key : pre-commit-3|${{ env.pythonLocation }}|${{ hashFiles('.pre-commit-config.yaml') }}
36+ - run : pre-commit run --show-diff-on-failure --color=always --all-files
37+ shell : bash
2038 build :
2139 strategy :
2240 matrix :
3048 runner : ubuntu-24.04-arm
3149 name : ${{ matrix.name }}
3250 runs-on : ${{ matrix.runner }}
51+ needs : pre-commit
3352 permissions :
3453 contents : read
3554 packages : write
5372 runCmd : |
5473 set -eux pipefail
5574
56- # Check
57- pre-commit run --show-diff-on-failure --color=always --all-files || exit 1
58-
5975 # Create builder for multi-arch builds
6076 ./scripts/create_builder.sh
6177
You can’t perform that action at this time.
0 commit comments