Skip to content

Commit

Permalink
Update clang format check.
Browse files Browse the repository at this point in the history
  • Loading branch information
TheWiseNoob committed Dec 6, 2023
1 parent 4c6bb24 commit b51ce10
Showing 1 changed file with 10 additions and 1 deletion.
11 changes: 10 additions & 1 deletion .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,4 +9,13 @@ jobs:
- name: Install Dependencies
run: sudo apt-get install clang-format
- name: Link
run: run: echo "FORMAT_ISSUES=$(cd src && clang-format --dry-run *.cc *.h)" >> $GITHUB_ENV
id: format_check
run: |
cd src
errors=$(clang-format --dry-run *.cc *.h 2>&1; echo $?)
if [ -z "$errors" ]
then
echo "Format is valid. Nice!"
else
echo "::error::Formatting errors exist."
fi

0 comments on commit b51ce10

Please sign in to comment.