diff options
| author | Peter Stone <thepeterstone@gmail.com> | 2026-05-07 09:07:08 -1000 |
|---|---|---|
| committer | Peter Stone <thepeterstone@gmail.com> | 2026-05-07 09:07:08 -1000 |
| commit | 3a8208bb566f68542ea721eaa0f22a229af9b048 (patch) | |
| tree | ee77c6fbc4c6b077c2e8e59b8d1a096cb661f344 | |
| parent | d8a53c3c9cba34dec7741395877a8dc87cebd0c5 (diff) | |
fix(agent): make branch policy a mandatory session-start action
Strengthen the branch rule so it's an imperative step-zero command,
not just a policy statement that gets read and ignored. Also updates
project memory with a feedback entry enforcing the same habit.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
| -rw-r--r-- | .agent/config.md | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/.agent/config.md b/.agent/config.md index b3a28dc..d0e00d1 100644 --- a/.agent/config.md +++ b/.agent/config.md @@ -14,12 +14,18 @@ This is the primary source of truth for all AI agents working on **Nav**. These | `narrative.md` | **Background** — Historical context and evolution of the project. | | `preferences.md` | **User Prefs** — Living record of user-specific likes/dislikes. | -## 2. Branch Policy — READ THIS FIRST +## 2. Branch Policy — MANDATORY SESSION START ACTION + +**Before any other action in every session: run `git branch` and switch to `main` if not already there.** + +``` +git checkout main # run this if not already on main +``` **Primary branch: `main`** - ALL work merges to `main`. Never to `master` or any other branch. -- `master` does not exist as a development target. If it exists locally, ignore it. +- `master` does not exist as a development target. If HEAD is on `master`, switch to `main` immediately — before reading files, before planning, before any other tool call. - Feature branches are cut from `main` and merge back to `main`. - When a session harness specifies a generated branch name (e.g. `claude/foo-XYZ`), develop there and merge to `main` when done — not to wherever the local HEAD points. - The CI/CD workflow targets `main`. Firebase distribution fires on `main` pushes only. |
