From bf9fa4d76aa7af55e15145384a5a6350d4f2a81e Mon Sep 17 00:00:00 2001 From: dkim19375 <65050767+dkim19375@users.noreply.github.com> Date: Sat, 14 Oct 2023 20:26:15 -0400 Subject: [PATCH] Fix rust formatting check --- .github/workflows/check-format.yml | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/.github/workflows/check-format.yml b/.github/workflows/check-format.yml index 8ae5321..9326e0b 100644 --- a/.github/workflows/check-format.yml +++ b/.github/workflows/check-format.yml @@ -8,12 +8,13 @@ env: CARGO_TERM_COLOR: always jobs: - build: + check-format: runs-on: ubuntu-latest steps: + - uses: actions/checkout@v4 - name: Set cargo fmt output - run: export FMT_OUTPUT=$(cargo fmt --message-format short) + run: echo "FMT_OUTPUT=$(cargo fmt --message-format short)" >> $GITHUB_ENV - name: Print cargo fmt output - run: echo $FMT_OUTPUT + run: echo "${{ env.FMT_OUTPUT }}" - name: Check cargo fmt output - run: if [ -z $FMT_OUTPUT ]; then exit 1; fi \ No newline at end of file + run: if [ -n "${{ env.FMT_OUTPUT }}" ]; then exit 1; fi \ No newline at end of file