2026-02-27T10-04-14_auto_memory/memories.db-wal, memory/2026-02-27-block-co

This commit is contained in:
Nicholai Vogel 2026-02-27 03:04:14 -07:00
parent 850923be36
commit c756deb892
3 changed files with 19 additions and 0 deletions

View File

@ -0,0 +1,19 @@
# 2026-02-27 Session Notes
## Block Co-Authored-By Attribution Hook
Nicholai requested implementation of a PreToolUse hook to block git commits containing Claude's automatic `Co-Authored-By:` attribution. The plan specifies creating a bash script at `~/.claude/hooks/block-coauthor.sh` that:
- Reads PreToolUse JSON payload from stdin
- Extracts the git command via jq
- Searches for the pattern `Co-Authored-By:.*Claude` (case-insensitive)
- Returns `permissionDecision: "deny"` if found, otherwise allows execution
The hook must be registered in `~/.claude/settings.json` with a 5-second timeout and status message.
Session work:
- Reviewed existing settings.json structure to understand hook architecture
- Confirmed hook format uses event-based triggers (SessionStart, UserPromptSubmit, SessionEnd)
- Ready to implement both the script and settings modification
Next steps: Create the hook script and update settings.json configuration.

Binary file not shown.

Binary file not shown.