File tree Expand file tree Collapse file tree 1 file changed +29
-2
lines changed
Expand file tree Collapse file tree 1 file changed +29
-2
lines changed Original file line number Diff line number Diff line change 1111 - v14-alpha
1212
1313jobs :
14+ build-matrix :
15+ name : Build matrix
16+ runs-on : ubuntu-latest
17+ outputs :
18+ build_matrix : ${{ steps.set-matrix.outputs.build_matrix }}
19+ steps :
20+ - name : Checkout
21+ uses : actions/checkout@v4
22+ with :
23+ sparse-checkout : |
24+ .github/workflows/matrix.json
25+ sparse-checkout-cone-mode : false
26+ - id : set-matrix
27+ shell : bash
28+ run : |
29+ if [ "$ACT" == true ]; then
30+ echo "build_matrix=$( cat .github/workflows/matrix.json | jq --monochrome-output --compact-output '[.[] | select(.RUN_LOCALLY)]' )" >> $GITHUB_OUTPUT
31+ else
32+ echo "build_matrix=$( cat .github/workflows/matrix.json | jq --monochrome-output --compact-output )" >> $GITHUB_OUTPUT
33+ fi
34+
1435 lint-and-test :
15- name : Lint and test
16- runs-on : ubuntu-22.04
36+ name : Lint and test (${{ matrix.build.NAME }})
37+ needs : build-matrix
38+ runs-on : ${{ matrix.build.OS }}
39+ strategy :
40+ fail-fast : true
41+ matrix :
42+ build : ${{ fromJson(needs.build-matrix.outputs.build_matrix) }}
1743 steps :
1844 - name : Checkout
1945 uses : actions/checkout@v4
2046 - name : Install rust toolchain
2147 uses : dtolnay/rust-toolchain@stable
2248 with :
49+ targets : ${{ matrix.build.TARGET }}
2350 components : rustfmt, clippy
2451 - name : Set up cargo cache
2552 uses : Swatinem/rust-cache@v2
You can’t perform that action at this time.
0 commit comments