From 5da44fa4b94a315ffaef94023a331aa02aa3b650 Mon Sep 17 00:00:00 2001 From: x12xx12x <44411062+12xx12@users.noreply.github.com> Date: Mon, 5 Jun 2023 22:37:47 +0200 Subject: Update clang-tidy.sh (#5477) --- clang-tidy.sh | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/clang-tidy.sh b/clang-tidy.sh index ec9a226a6..a0a1ff537 100755 --- a/clang-tidy.sh +++ b/clang-tidy.sh @@ -2,9 +2,16 @@ set -e +LOCALSTRING="local" + +if [ "$3" = "$LOCALSTRING" ]; then + REGEX="/cuberite/src/\.?[^\.]" +else + REGEX="cuberite_[^/\.]+/src/\.?[^\.]" +fi + FIXES_FILE="tidy-fixes.yaml" -REGEX="cuberite_[^/\.]+/src/\.?[^\.]" -ARGS="-header-filter $REGEX -quiet -export-fixes $FIXES_FILE "$@" $REGEX" +ARGS="-header-filter $REGEX -quiet -export-fixes $FIXES_FILE $* $REGEX" # Generate the compilation database mkdir -p tidy-build -- cgit v1.2.3