-
Notifications
You must be signed in to change notification settings - Fork 25
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Check formatting as part of the CI (#2193)
Succeed if all source files are well formated. Fail otherwise, and display ill-formatted files. --------- Co-authored-by: Abdoulbari Zaher <[email protected]>
- Loading branch information
Showing
77 changed files
with
2,117 additions
and
1,584 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
name: Check cpp formatting | ||
|
||
on: | ||
push: | ||
branches: | ||
- develop | ||
- feature/* | ||
- features/* | ||
- fix/* | ||
|
||
jobs: | ||
build: | ||
name: clang-format | ||
|
||
runs-on: ubuntu-24.04 | ||
|
||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
|
||
- name: Print version | ||
run: clang-format --version | ||
|
||
- name: clang-format | ||
run: cd src && ./format-code.sh | ||
|
||
- name: git diff | ||
run: | | ||
DIFF=`git status --porcelain` | ||
if [[ $DIFF ]]; then | ||
echo "The following files are not well formatted" | ||
echo "$DIFF" | ||
exit 1 | ||
else | ||
echo "Code is well formatted, congrats !" | ||
fi |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,4 @@ | ||
|
||
// Generated from Expr.g4 by ANTLR 4.13.1 | ||
|
||
|
||
#include "ExprBaseVisitor.h" | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.