Files
AIPass/.claude
AIPassandClaude Opus 4.6 8fedc053ec feat(system): credential model, stderr migration, DPLAN/FPLAN docs (#41)
* feat(system): stderr routing migration Phase 3 — 10 branches migrated (FPLAN-0033)

Autonomous 3-wave migration: 15+ agents across 10 branches converted
error/warning prints to CLI stderr functions. Seedgo stderr_routing
checker refined (false positive fix for section headers). System avg
49%→94%. Skills self-fixed (100%). Credential model DPLAN updated.
AIPASS.md moved to ~/.claude/CLAUDE.md (global culture layer).

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* fix(system): stderr routing cleanup — remaining violations fixed

Final wave: ai_mail, backup, seedgo, commons, daemon migrated to
CLI stderr functions. System stderr_routing avg now 97% (11 branches
at 100%). Seedgo checker refinement confirmed (false positives
eliminated). Only backup/google_drive_sync has remaining prints.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* feat(system): /prep command + cleanup memo and pre-compact hook

New /prep slash command for pre-compact preparation: saves memories,
updates plans, checks git/inbox, flags loose ends. Workflow: /prep
then /compact. Cleaned up /memo (stale field refs, flow.local.md →
STATUS.local.md). Pre-compact hook: removed misleading Notepad
reference, points to local.json and STATUS.local.md instead.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* docs(flow): DPLAN/FPLAN distinction in global prompt + DPLAN template self-documentation

Global prompt now explains DPLAN vs FPLAN with brief breadcrumbs and adds
the missing `master` command. DPLAN template now opens with a "What is a
DPLAN?" section so agents understand the plan type on first read.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-14 18:57:23 -07:00
..
2026-03-07 21:02:14 +00:00

.claude/ — Claude Code Configuration

This directory configures Claude Code for the AIPass project.

Settings — Two Files, Clear Separation

File Name What it does
~/.claude/settings.json Anthropic settings All hooks, sounds, statusline, plugins. Fires everywhere.
.claude/settings.json (this dir) Project settings Permissions only. No hooks.

Why this split: Claude Code project settings only fire when launched from the repo root. We launch from branch subdirectories (src/aipass/{name}/), so hooks must live in Anthropic settings with absolute paths.

Project settings = permissions. That's it.

Hooks — Two Locations, No Duplication

Anthropic hooks (~/.claude/hooks/)

General-purpose scripts that work on any project.

Script Event What it does
tool_use_sound.py PreToolUse Plays keypress sound on tool calls
auto_fix_diagnostics.py PostToolUse Syntax check after file edits
stop_sound.py Stop Sound on stop
notification_sound.py Notification Sound on notification

Project hooks (AIPass/.claude/hooks/)

AIPass-specific scripts. Referenced from Anthropic settings with absolute paths.

Script Event What it does
branch_prompt_loader.py UserPromptSubmit Finds .aipass/aipass_local_prompt.md from CWD, injects branch context
identity_injector.py UserPromptSubmit Reads .trinity/passport.json, injects role/traits/purpose
email_notification.py UserPromptSubmit Checks .ai_mail.local/inbox.json for unread messages
pre_compact.py PreCompact Saves session context before compaction

The global prompt (aipass_global_prompt.md) is injected via a cat command in Anthropic settings — no script needed.

What Gets Injected Every Turn

  1. Global Prompt — cat .aipass/aipass_global_prompt.md (system context, terminology, rules)
  2. Branch Prompt — branch_prompt_loader.py (branch-specific instructions from CWD)
  3. Identity — identity_injector.py (compact passport summary: role, traits, purpose)
  4. Email — email_notification.py (notification only if unread mail exists)

Directory Structure

.claude/
├── settings.json              # Permissions only (no hooks)
├── hooks/                     # AIPass-specific hook scripts
│   ├── branch_prompt_loader.py
│   ├── identity_injector.py
│   ├── email_notification.py
│   └── pre_compact.py
├── commands/
│   └── memo.md                # /memo — memory update workflow
├── sounds/                    # Audio files (symlinked from ~/.claude/sounds)
└── README.md

Adding a New Hook

  1. Create the script in .claude/hooks/
  2. Add one entry to ~/.claude/settings.json (Anthropic settings) with the absolute path
  3. Done — no changes to project settings

Permissions

Defined in settings.json:

  • Denied: git reset, git rebase, git config, git push --force, EnterPlanMode
  • Default mode: acceptEdits