Skip to content

Commit

Permalink
fixup! ci: make matrix size more flexible
Browse files Browse the repository at this point in the history
  • Loading branch information
kaspar030 committed Nov 17, 2023
1 parent 3fd8340 commit 7ed0491
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,10 @@ jobs:
strategy:
fail-fast: false
matrix:
partition: [ 1..6 ]
partition:
- "${{ strategy.job-index + 1 }}/${{strategy.job-total}}"
- "${{ strategy.job-index + 1 }}/${{strategy.job-total}}"
- "${{ strategy.job-index + 1 }}/${{strategy.job-total}}"

steps:
- name: Run sccache-cache
Expand All @@ -35,7 +38,7 @@ jobs:
- name: rust cache
uses: Swatinem/rust-cache@v2
with:
key: "${{ strategy.job-index }}/${{ strategy.job-total }}"
key: "${{ matrix.partition }}"

- uses: taiki-e/install-action@v2
with:
Expand All @@ -57,7 +60,7 @@ jobs:
run: |
sccache --start-server || true # work around https://github.com/ninja-build/ninja/issues/2052
laze build --partition hash:${{ strategy.job-index }}/${{ strategy.job-total }} --builders nrf52840dk,rpi-pico -g
laze build --partition hash:${{ matrix.partition }} --builders nrf52840dk,rpi-pico -g
CI-success:
if: ${{ always() }}
Expand Down

0 comments on commit 7ed0491

Please sign in to comment.