From 7ade68379f6c9bb8a99f0c835f991a066897d4e5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mat=C4=9Bj=20Laitl?= Date: Fri, 7 Jan 2022 08:57:43 +0000 Subject: [PATCH] Run rustfmt on CI (#178) * Run rustfmt on CI * Run rustfmt on nightly toolchain, outside test matrix Rustfmt doesn't need dependencies and should be platform-agnostic anyway. --- .github/workflows/rust.yml | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/.github/workflows/rust.yml b/.github/workflows/rust.yml index 8073c0e..e6c652b 100644 --- a/.github/workflows/rust.yml +++ b/.github/workflows/rust.yml @@ -57,3 +57,19 @@ jobs: with: command: clippy args: --all-targets -- -D warnings + + fmt: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - uses: actions-rs/toolchain@v1 + with: + profile: minimal + toolchain: nightly + override: true + components: rustfmt + - name: Rustfmt + uses: actions-rs/cargo@v1 + with: + command: fmt + args: --all -- --check