[WIP] Migate to rust-toolchain #205
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
on: | |
pull_request: | |
push: | |
branches: | |
- master | |
name: Merge checks | |
jobs: | |
check: | |
name: Check | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout sources | |
uses: actions/checkout@v4 | |
- name: Run cargo check | |
uses: dtolnay/rust-toolchain@stable | |
run: cargo test | |
test: | |
name: Tests | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout sources | |
uses: actions/checkout@v4 | |
- name: Run cargo test | |
uses: dtolnay/rust-toolchain@stable | |
run: cargo test | |
lints: | |
name: Lints | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout sources | |
uses: actions/checkout@v4 | |
- name: Install stable toolchain | |
uses: actions-rs/toolchain@v1 | |
with: | |
profile: minimal | |
toolchain: nightly | |
override: true | |
components: rustfmt, clippy | |
- name: Run cargo fmt | |
uses: actions-rs/cargo@v1 | |
with: | |
command: fmt | |
args: --all -- --check | |
- name: Run cargo clippy | |
uses: actions-rs/cargo@v1 | |
with: | |
command: clippy | |
args: -- -D warnings | |
nix-flake: | |
name: Validate nix flake | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Install nix | |
uses: DeterminateSystems/nix-installer-action@v4 | |
- name: Magic nix cache | |
uses: DeterminateSystems/magic-nix-cache-action@v2 | |
- name: Build | |
run: nix build .#dev.presenterm | |
bat-assets: | |
name: Validate bat assets | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout sources | |
uses: actions/checkout@v2 | |
- name: Verify assets | |
run: ./bat/verify.sh |