summaryrefslogtreecommitdiff
path: root/scripts/check-no-tabs.sh
diff options
context:
space:
mode:
authorPhilip Dubé <159546+serprex@users.noreply.github.com>2026-09-19 18:09:26 +0000
committerGitHub <noreply@github.com>2026-09-19 18:09:26 +0000
commit5fee87c23ebcdf8cf11078a9ecaa6e474498787f (patch)
tree49e91d845fac0bfb72f9e30aaf7a50029b7545c9 /scripts/check-no-tabs.sh
parent27a66925bfa80cdff0583b9434657ed8842102db (diff)
Replace tabs with spaces (#7223)HEADdevelop
Diffstat (limited to 'scripts/check-no-tabs.sh')
-rwxr-xr-xscripts/check-no-tabs.sh9
1 files changed, 9 insertions, 0 deletions
diff --git a/scripts/check-no-tabs.sh b/scripts/check-no-tabs.sh
new file mode 100755
index 000000000..b469baed9
--- /dev/null
+++ b/scripts/check-no-tabs.sh
@@ -0,0 +1,9 @@
+#!/bin/sh
+# Fail if any C/C++ source in soh/ outside soh/include contains a tab.
+
+cd "$(dirname "$0")/.." || exit 2
+
+if git grep -n "$(printf '\t')" -- 'soh/*.c' 'soh/*.cpp' 'soh/*.h' 'soh/*.hpp' ':!soh/include'; then
+ echo "replace tabs with spaces"
+ exit 1
+fi