File tree Expand file tree Collapse file tree 2 files changed +9
-2
lines changed Expand file tree Collapse file tree 2 files changed +9
-2
lines changed Original file line number Diff line number Diff line change 3131 steps :
3232 - name : checkout repository
3333 uses : actions/checkout@v4
34+ - name : install clang 14
35+ uses : KyleMayes/install-llvm-action@v2
36+ with :
37+ version : " 14"
3438 - name : check format
3539 run : ./format-files.sh check
3640 - name : configure
Original file line number Diff line number Diff line change @@ -15,7 +15,10 @@ CLANG_FORMAT_VERSION=$(clang-format --version 2>/dev/null)
1515if [[ $CLANG_FORMAT_VERSION =~ ([0-9]+)\. ]]; then
1616 MAJOR_VERSION=${BASH_REMATCH[1]}
1717 if (( MAJOR_VERSION < 13 )) ; then
18- echo " clang-format version >= 13 required, got $MAJOR_VERSION "
18+ echo " clang-format version >= 13 and < 18 required, got $MAJOR_VERSION "
19+ exit 1
20+ elif (( MAJOR_VERSION > 18 )) ; then # PointerAlignment: Left, v18 wants `T C::* member` v14 wants `T C::*member`
21+ echo " clang-format version >= 13 and < 18 required, got $MAJOR_VERSION "
1922 exit 1
2023 else
2124 echo " clang-format version $MAJOR_VERSION "
3437find " ${PROJ_ROOT} " -type f \
3538 \( -name " *.cpp" -o -name " *.c" -o -name " *.hpp" -o -name " *.h" \) \
3639 -not -path " ${PROJ_ROOT} /build/*" \
37- -print0 | xargs -0 clang-format $EXTRA_FLAGS --style=file --verbose -i
40+ -print0 | xargs -0 clang-format $EXTRA_FLAGS --style=file --verbose -i
You can’t perform that action at this time.
0 commit comments