diff --git a/.github/workflows/rust-checks.yml b/.github/workflows/rust-checks.yml new file mode 100644 index 0000000..b29c7d4 --- /dev/null +++ b/.github/workflows/rust-checks.yml @@ -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