Skip to content

An agentic skills framework & software development methodology that works.

fix(systematic-debugging): match find -path ./ prefix in find-polluter.sh (#2011)

dev_Hakaze6015d37fe623
diff --git a/skills/systematic-debugging/find-polluter.sh b/skills/systematic-debugging/find-polluter.sh
index 1d71c5607..d2261c466 100755
--- a/skills/systematic-debugging/find-polluter.sh
+++ b/skills/systematic-debugging/find-polluter.sh
@@ -18,9 +18,13 @@ echo "🔍 Searching for test that creates: $POLLUTION_CHECK"
echo "Test pattern: $TEST_PATTERN"
echo ""
-# Get list of test files
-TEST_FILES=$(find . -path "$TEST_PATTERN" | sort)
-TOTAL=$(echo "$TEST_FILES" | wc -l | tr -d ' ')
+# Get list of test files (find . emits ./-prefixed paths)
+TEST_FILES=$(find . -path "./$TEST_PATTERN" | sort)
+if [ -z "$TEST_FILES" ]; then
+ TOTAL=0
+else
+ TOTAL=$(printf '%s\n' "$TEST_FILES" | wc -l | tr -d ' ')
+fi
echo "Found $TOTAL test files"
echo ""