diff --git a/AGENTS.md b/AGENTS.md index 0eedb7a..a63c66a 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -102,6 +102,10 @@ View (thin data-provider) This project uses the GSD (Get Shit Done) planning workflow. Planning artifacts live in `.planning/`. +### Worktree-first rule (Non-Negotiable) + +Before any GSD workflow or agent edits project files, create or switch into a dedicated git worktree for that GSD task. Discussion, read-only inspection, and status checks may run in the main checkout, but planning artifacts, code changes, docs changes, and workflow state mutations must happen inside the task worktree. If a workflow would edit files and no worktree exists yet, stop and create one first. + ### Key files | File | Purpose | diff --git a/CLAUDE.md b/CLAUDE.md index de607b4..5c68995 100644 --- a/CLAUDE.md +++ b/CLAUDE.md @@ -108,6 +108,10 @@ View (thin data-provider) This project uses the GSD (Get Shit Done) planning workflow. Planning artifacts live in `.planning/`. +### Worktree-first rule (Non-Negotiable) + +Before any GSD workflow or agent edits project files, create or switch into a dedicated git worktree for that GSD task. Discussion, read-only inspection, and status checks may run in the main checkout, but planning artifacts, code changes, docs changes, and workflow state mutations must happen inside the task worktree. If a workflow would edit files and no worktree exists yet, stop and create one first. + ### Key files | File | Purpose |