Skip to content

Commit

Permalink
Optimize CI (#1344)
Browse files Browse the repository at this point in the history
Parameterize cargo flags into matrix for parallel building and better caching
  • Loading branch information
NobodyXu authored Jan 3, 2025
1 parent db78cba commit 18307cf
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ jobs:
mingw64,
windows-2019,
]
cargo_flags: ['', '--release', '--features parallel']
include:
- build: stable
os: ubuntu-latest
Expand Down Expand Up @@ -135,9 +136,7 @@ jobs:
if: startsWith(matrix.build, 'windows-clang')
- run: cargo update
- uses: Swatinem/rust-cache@v2
- run: cargo test ${{ matrix.no_run }} --workspace --target ${{ matrix.target }}
- run: cargo test ${{ matrix.no_run }} --workspace --target ${{ matrix.target }} --release
- run: cargo test ${{ matrix.no_run }} --workspace --target ${{ matrix.target }} --features parallel
- run: cargo test ${{ matrix.no_run }} --workspace --target ${{ matrix.target }} ${{ matrix.cargo_flags }}

# This is separate from the matrix above because there is no prebuilt rust-std component for these targets.
check-tvos:
Expand Down

0 comments on commit 18307cf

Please sign in to comment.