Add release and test github workflows #14
Workflow file for this run
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
name: Tests | |
on: | |
push: | |
branches: [main] | |
pull_request: | |
branches: [main] | |
jobs: | |
cli: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Fetch the repository code | |
uses: actions/checkout@v4 | |
- name: Cache Cargo registry and binaries | |
uses: actions/cache@v4 | |
with: | |
path: | | |
~/.cargo/registry | |
~/.cargo/git | |
target | |
~/.cargo/bin | |
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}-${{ hashFiles('**/rust-toolchain') }} | |
id: cache-cargo | |
- name: Tests and linting | |
run: | | |
make test_cli | |
lib: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Fetch the repository code | |
uses: actions/checkout@v4 | |
- name: Cache Cargo registry and binaries | |
uses: actions/cache@v4 | |
with: | |
path: | | |
~/.cargo/registry | |
~/.cargo/git | |
target | |
~/.cargo/bin | |
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}-${{ hashFiles('**/rust-toolchain') }} | |
id: cache-cargo-msvr | |
- name: Test the minimum supported version of Rust | |
run: | | |
make test_msvr |