diff options
Diffstat (limited to '.claude/hooks/validate-el.sh')
| -rwxr-xr-x | .claude/hooks/validate-el.sh | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/.claude/hooks/validate-el.sh b/.claude/hooks/validate-el.sh index 803badf8..b811bcc2 100755 --- a/.claude/hooks/validate-el.sh +++ b/.claude/hooks/validate-el.sh @@ -35,6 +35,13 @@ f="$(jq -r '.tool_input.file_path // .tool_response.filePath // empty')" [ -z "$f" ] && exit 0 [ "${f##*.}" = "el" ] || exit 0 +# Only validate in-tree files. Files outside PROJECT_ROOT are owned by +# their own project's hooks (when a Claude session runs there). +case "$f" in + "$PROJECT_ROOT"/*) ;; # in-tree, continue + *) exit 0 ;; # out-of-tree, skip +esac + MAX_AUTO_TEST_FILES=20 # skip if more matches than this (large test suites) # --- Phase 1: syntax + byte-compile --- |
