Merge pull request #752 from chrisglass/add-cargo-fmt-check
Introduce a "cargo fmt" github action gate
This commit is contained in:
commit
7ce2974273
1 changed files with 26 additions and 0 deletions
26
.github/workflows/rust-checks.yml
vendored
Normal file
26
.github/workflows/rust-checks.yml
vendored
Normal file
|
|
@ -0,0 +1,26 @@
|
|||
name: Rust Checks
|
||||
|
||||
on:
|
||||
push:
|
||||
branches: [master]
|
||||
pull_request:
|
||||
branches: [master]
|
||||
|
||||
env:
|
||||
CARGO_TERM_COLOR: always
|
||||
|
||||
jobs:
|
||||
fmt:
|
||||
name: Rustfmt
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Checkout repository
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Install Rust
|
||||
uses: dtolnay/rust-toolchain@stable
|
||||
with:
|
||||
components: rustfmt
|
||||
|
||||
- name: Check formatting
|
||||
run: cargo fmt --all -- --check
|
||||
Loading…
Add table
Add a link
Reference in a new issue