Stats
Actions
Tags
From claude-obsidian
Maintains a wiki hot cache by detecting changes on Stop, restoring context after compaction, auto-committing wiki/ edits after Write/Edit, and loading session context on startup. Writes files, executes git and shell scripts.
4 events · 6 hooks
Safety signals detected in this hook configuration
Where this hook configuration is defined
Defined in hooks/hooks.json
Event handlers and matchers — expand Raw Configuration for the full JSON
cd "$PWD" && [ -d wiki ] && [ -d .git ] && git diff --name-only HEAD 2>/dev/null | grep -q '^wiki/' && echo 'WIKI_CHANGED: Wiki pages were modified this session. Please update wiki/hot.md with a brief summary of what changed (under 500 words). Use the hot cache format: Last Updated, Key Recent Facts, Recent Changes, Active Threads. Keep it factual. Overwrite the file completely. It is a cache, not a journal.' || trueWrite|Edit[ -d .git ] || exit 0; [ -f .vault-meta/auto-commit.disabled ] && exit 0; if [ -x scripts/wiki-lock.sh ]; then LOCK_LIST=$(bash scripts/wiki-lock.sh list 2>/dev/null); LOCK_RC=$?; if [ "$LOCK_RC" != "0" ]; then mkdir -p .vault-meta 2>/dev/null; printf '%s wiki-lock list failed rc=%s; deferred auto-commit\n' "$(date '+%Y-%m-%dT%H:%M:%SZ')" "$LOCK_RC" >> .vault-meta/hook.log 2>/dev/null; exit 0; fi; if [ -n "$LOCK_LIST" ]; then exit 0; fi; fi; git add -- wiki/ .raw/ .vault-meta/ 2>/dev/null && (git diff --cached --quiet -- wiki/ .raw/ .vault-meta/ || git commit -m "wiki: auto-commit $(date '+%Y-%m-%d %H:%M')" -- wiki/ .raw/ .vault-meta/ 2>/dev/null) || truestartup|resume[ -f wiki/hot.md ] && cat wiki/hot.md || true[ -x scripts/wiki-lock.sh ] && bash scripts/wiki-lock.sh clear-stale --max-age 3600 >/dev/null 2>&1 || truenpx claudepluginhub agricidaniel/claude-obsidian --plugin claude-obsidian