Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 7 additions & 2 deletions formatcode.sh
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,15 @@ if [[ $OS = "Linux" || $OS = "Darwin" ]] ; then
fi

# Discover clang-format
if type clang-format-8 2> /dev/null ; then
CLANG_FORMAT=clang-format-8
if type clang-format-13 2> /dev/null ; then
CLANG_FORMAT=clang-format-13
else
CLANG_FORMAT=clang-format
V=$(clang-format --version)
if [[ $V != *13.0* ]] ; then
echo "warning: clang-format is not 13.0 (returned ${V})"
#exit 1
fi
fi

find . -type d \( -path ./deps \
Expand Down