Skip to content

Fix rust formatting check #22

Fix rust formatting check

Fix rust formatting check #22

Workflow file for this run

name: Check rust code formatting
on:
push:
pull_request:
env:
CARGO_TERM_COLOR: always
jobs:
check-format:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set cargo fmt output
run: echo "FMT_OUTPUT=$(cargo fmt --message-format short)" >> $GITHUB_ENV
- name: Print cargo fmt output
run: echo "${{ env.FMT_OUTPUT }}"
- name: Check cargo fmt output
run: if [ -n "${{ env.FMT_OUTPUT }}" ]; then exit 1; fi