Creates MEMORY.md index and 10 memory files documenting: - Scripts: context-load, start-claude, install-hooks, setup-formatters, git-status-report - Skills: /log, /reflect-logs, /reflect, /distill-best-practices, /linter Each file covers purpose, usage, how it works, and gotchas. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
28 lines
806 B
Markdown
28 lines
806 B
Markdown
# script: install-hooks
|
|
|
|
**Location:** `scripts/install-hooks.sh`
|
|
|
|
## Purpose
|
|
|
|
Symlinks all hook scripts from `claude-foundations/hooks/` into `~/.claude/hooks/` and prints the `settings.json` configuration to add.
|
|
|
|
## Usage
|
|
|
|
```bash
|
|
cd ~/dev/claude/projects/claude-foundations
|
|
scripts/install-hooks.sh
|
|
```
|
|
|
|
One-time setup. Re-run after adding new hooks.
|
|
|
|
## How it works
|
|
|
|
1. Iterates over `hooks/*.sh`
|
|
2. Creates symlinks in `~/.claude/hooks/` (force-overwrites existing)
|
|
3. Prints the JSON config for `~/.claude/settings.json` covering PreCompact and PostToolUse matchers
|
|
|
|
## Gotchas
|
|
|
|
- The printed JSON must be manually added to `settings.json` — the script doesn't edit it automatically.
|
|
- Symlinks mean the hook code stays in the repo; updates take effect immediately without re-running the script.
|