From 4c966ebdfcfe56a09aa0bb60d18721553e64b59e Mon Sep 17 00:00:00 2001 From: bchanot Date: Mon, 12 Oct 2026 22:51:37 +0200 Subject: [PATCH] fix(toggle-external): --help prints the whole header, all 14 tools usage() printed lines 3-26 with a hardcoded range, but the tool list runs to line 32, so 8 of the 14 tools were missing. It now reads `sed -n '3,/^# ====/p' | sed '$d'` and stops at the closing banner, with no line numbers. Logged in .claude/audits/BUGS-FOUND.md. --- lib/toggle-external.sh | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/lib/toggle-external.sh b/lib/toggle-external.sh index 5b54f9f..1f6ba68 100755 --- a/lib/toggle-external.sh +++ b/lib/toggle-external.sh @@ -347,7 +347,9 @@ list_all() { } usage() { - sed -n '3,26p' "$0" | sed 's/^# \?//' + # Header comment = lines 3 .. closing banner (dropped); no numeric range, + # so a longer tool list can no longer fall out of --help. + sed -n '3,/^# ====/p' "$0" | sed '$d' | sed 's/^# \?//' exit "${1:-0}" }