docs: add architecture awareness system — CLAUDE.md §13/§14 + ARCHITECTURE_BRIEF
Some checks failed
CI / Lint & TypeCheck (push) Has been cancelled
CI / Unit Tests (push) Has been cancelled
CI / Build Frontend (push) Has been cancelled
CI / Rust Check (push) Has been cancelled
CI / Security Scan (push) Has been cancelled
CI / E2E Tests (push) Has been cancelled
Some checks failed
CI / Lint & TypeCheck (push) Has been cancelled
CI / Unit Tests (push) Has been cancelled
CI / Build Frontend (push) Has been cancelled
CI / Rust Check (push) Has been cancelled
CI / Security Scan (push) Has been cancelled
CI / E2E Tests (push) Has been cancelled
- Activate CLAUDE.md with §13 architecture snapshot (auto-sync markers) and §14 anti-pattern warnings + scenario instructions - Fix dead link to non-existent STABILIZATION_DIRECTIVE.md - Update stale numbers (93→130 SaaS APIs, 171→182 Tauri commands, 13→15 admin pages) - Create docs/ARCHITECTURE_BRIEF.md as permanent architecture reference covering 10 subsystems (butler, chatstream, LLM drivers, client routing, SaaS auth, memory pipeline, Pipeline DSL, Hands, middleware, key paths) - Add /sync-arch skill for manual or workflow-triggered architecture sync - Add PostToolUse hook to remind doc sync after git commit/push - Update §8.3 completion flow to include architecture snapshot updates - Mark memory files (system_architecture, butler_mode) as migrated to BRIEF - Add ARCHITECTURE_BRIEF.md as top entry in MEMORY.md index
This commit is contained in:
28
.claude/hooks/arch-sync-check.js
Normal file
28
.claude/hooks/arch-sync-check.js
Normal file
@@ -0,0 +1,28 @@
|
||||
// arch-sync-check.js
|
||||
// PostToolUse hook: detects git commit/push and reminds to sync architecture docs
|
||||
// Reads tool input from stdin, outputs reminder if git operation detected
|
||||
|
||||
const CHUNKS = [];
|
||||
process.stdin.on('data', (c) => CHUNKS.push(c));
|
||||
process.stdin.on('end', () => {
|
||||
try {
|
||||
const input = JSON.parse(Buffer.concat(CHUNKS).toString());
|
||||
const toolName = input.tool_name || '';
|
||||
const toolInput = input.tool_input || {};
|
||||
|
||||
// Only check Bash tool calls
|
||||
if (toolName !== 'Bash') return;
|
||||
|
||||
const cmd = (toolInput.command || '').trim();
|
||||
|
||||
// Detect git commit or git push
|
||||
const isGitCommit = cmd.startsWith('git commit') || cmd.includes('&& git commit');
|
||||
const isGitPush = cmd.startsWith('git push') || cmd.includes('&& git push');
|
||||
|
||||
if (isGitCommit || isGitPush) {
|
||||
console.log('[arch-sync] Architecture docs may need updating. Run /sync-arch or update CLAUDE.md §13 + ARCHITECTURE_BRIEF.md as part of §8.3 completion flow.');
|
||||
}
|
||||
} catch {
|
||||
// Silently ignore parse errors
|
||||
}
|
||||
});
|
||||
Reference in New Issue
Block a user