diff options
Diffstat (limited to '.github/workflows/fmt.yml')
-rw-r--r-- | .github/workflows/fmt.yml | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/.github/workflows/fmt.yml b/.github/workflows/fmt.yml new file mode 100644 index 0000000..40b1738 --- /dev/null +++ b/.github/workflows/fmt.yml @@ -0,0 +1,26 @@ +name: fmt + +on: + push: + branches: [ "main" ] + pull_request: + branches: [ "main" ] + +env: + CARGO_TERM_COLOR: always + +jobs: + build: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - name: "Install Rust" + uses: dtolnay/rust-toolchain@nightly + with: + components: rustfmt + - name: Check formatting + run: | + source $HOME/.cargo/env + cargo +nightly fmt --all -- --check + + |