summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorx12xx12x <44411062+12xx12@users.noreply.github.com>2023-06-05 22:37:47 +0200
committerGitHub <noreply@github.com>2023-06-05 22:37:47 +0200
commit5da44fa4b94a315ffaef94023a331aa02aa3b650 (patch)
tree76e7c48acbcc3f71880bf83c7b5f4ff05caf5a8b
parentAdd Class and Function Identifier Macro (#5481) (diff)
downloadcuberite-5da44fa4b94a315ffaef94023a331aa02aa3b650.tar
cuberite-5da44fa4b94a315ffaef94023a331aa02aa3b650.tar.gz
cuberite-5da44fa4b94a315ffaef94023a331aa02aa3b650.tar.bz2
cuberite-5da44fa4b94a315ffaef94023a331aa02aa3b650.tar.lz
cuberite-5da44fa4b94a315ffaef94023a331aa02aa3b650.tar.xz
cuberite-5da44fa4b94a315ffaef94023a331aa02aa3b650.tar.zst
cuberite-5da44fa4b94a315ffaef94023a331aa02aa3b650.zip
Diffstat (limited to '')
-rwxr-xr-xclang-tidy.sh11
1 files 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