mirror of
https://github.com/fralx/LimeReport.git
synced 2025-10-02 03:53:19 +03:00
Define code style and format all source file using clang-format-14
except those placed in 3rdparty directories.
This commit is contained in:
11
tools/check_code_style.sh
Executable file
11
tools/check_code_style.sh
Executable file
@@ -0,0 +1,11 @@
|
||||
#!/bin/bash
|
||||
|
||||
FORMATTER="clang-format-14"
|
||||
|
||||
find . -type f \
|
||||
-regextype posix-extended -regex '^.*\.(cpp|c\+\+|cxx|cc|h|hh|hpp|h\+\+|hxx)$' \
|
||||
-not -path '*3rdparty*' \
|
||||
-exec ${FORMATTER} -i -style=file {} \;
|
||||
|
||||
git status > /dev/null
|
||||
git diff-index --exit-code --name-only HEAD
|
Reference in New Issue
Block a user