build: fix building with clang

This commit is contained in:
2024-12-01 17:09:58 +00:00
parent 4d594e9463
commit c5f4a1db71
3 changed files with 38 additions and 2 deletions

8
scripts/check-format.sh Executable file
View File

@ -0,0 +1,8 @@
#!/bin/bash
# Go to repository root
cd "$(dirname "$0")/.." || exit 2
CLANG_FORMAT_BIN="${CLANG_FORMAT_BIN:-clang-format}"
find ./src -iname '*.hpp' -o -iname '*.cpp' | xargs $CLANG_FORMAT_BIN -Werror -ferror-limit=1 --dry-run