Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions hooks/scripts/read_config.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@
# Returns: value for key, or default if key/file missing.
# Default default: "true" (preserves existing behaviour when no config exists).
#
# Supported keys: git, session_capture, disable_plugin_hooks
#
# Migration: old marker files (cat face text) have no YAML keys,
# so grep returns nothing → defaults apply → behaviour unchanged.

Expand Down
10 changes: 10 additions & 0 deletions hooks/scripts/vaultguard.sh
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,11 @@ git: true
session_capture: true
EOF
fi
# Check if plugin hooks are disabled
DISABLE_PLUGIN_HOOKS=$("$(dirname "$0")/read_config.sh" disable_plugin_hooks false)
if [ "$DISABLE_PLUGIN_HOOKS" = "true" ]; then
exit 1
fi
exit 0
fi

Expand All @@ -34,6 +39,11 @@ if [ -f ops/config.yaml ] || [ -f .claude/hooks/session-orient.sh ]; then
git: true
session_capture: true
EOF
# Check if plugin hooks are disabled
DISABLE_PLUGIN_HOOKS=$("$(dirname "$0")/read_config.sh" disable_plugin_hooks false)
if [ "$DISABLE_PLUGIN_HOOKS" = "true" ]; then
exit 1
fi
exit 0
fi

Expand Down
3 changes: 2 additions & 1 deletion skills/setup/SKILL.md
Original file line number Diff line number Diff line change
Expand Up @@ -1531,8 +1531,9 @@ session_capture: true
Keys and defaults:
- `git: true` — auto-commit on writes (auto-commit.sh)
- `session_capture: true` — session JSON capture on start (session-orient.sh)
- `disable_plugin_hooks: false` — set to `true` to disable all plugin hooks (use when project-local hooks cover everything)

Omitted keys default to `true`, so a minimal marker file (or even an empty file) preserves full default behaviour.
Omitted keys default to `false` for `disable_plugin_hooks` and `true` for all others, so a minimal marker file (or even an empty file) preserves full default behaviour.

---

Expand Down