🦀 Migrated project to Rust 🦀 (#2) #27
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
on: | |
pull_request: | |
push: | |
branches: | |
- main | |
name: Continuous integration | |
jobs: | |
test: | |
name: "Test" | |
strategy: | |
fail-fast: true | |
matrix: | |
cmd: | |
- check | |
- fmt --all -- --check | |
- clippy -- -D warnings | |
- doc | |
- test | |
- build --release | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: dtolnay/rust-toolchain@stable | |
- uses: actions/cache@v4 | |
with: | |
path: | | |
~/.cargo/bin/ | |
~/.cargo/registry/index/ | |
~/.cargo/registry/cache/ | |
~/.cargo/git/db/ | |
target/ | |
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }} | |
- run: cargo ${{ matrix.cmd }} | |
conclude: | |
runs-on: ubuntu-latest | |
name: All tests passed | |
needs: [test] | |
steps: | |
- run: echo '### Good job! All the tests passed 🚀' >> $GITHUB_STEP_SUMMARY |