Skip to content

Commit

Permalink
Use actions-rs for formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
AlexvZyl authored Oct 12, 2022
1 parent 6debcf7 commit 8bbb18b
Showing 1 changed file with 13 additions and 4 deletions.
17 changes: 13 additions & 4 deletions .github/workflows/format.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,19 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Install nightly
run: rustup install nightly
- name: Run rustfmt
run: cargo +nightly fmt --all
- name: Get nightly toolchain
uses: actions-rs/toolchain@v1
with:
toolchain: nightly
override: true
profile: minimal
components: rustfmt
- name: Run cargo fmt
uses: actions-rs/cargo@v1
with:
command: fmt
args: --all -- --check

- name: Push changes
run: |
if [[ $(git diff --stat) != '' ]]; then
Expand Down

0 comments on commit 8bbb18b

Please sign in to comment.