diff --git a/skills/WORKFLOW.md b/skills/WORKFLOW.md index 9ad7dae5..de876df4 100644 --- a/skills/WORKFLOW.md +++ b/skills/WORKFLOW.md @@ -233,6 +233,22 @@ that resolve from any sibling repo: drift-checks them (`check`). See `PyAutoMind/complete/AGENTS.md` (issues #71/#81). - `source PyAutoMind/scripts/prompt_sync.sh` → `prompt_sync_push ""` (commit+push registry) +`prompt_sync_push` pushes **the branch you are on**, never a hardcoded `main` — +on a laptop that branch is `main`; on a branch-scoped surface (the phone, +claude.ai/code, any `claude/**` flow) it is the session's branch. **That is the +whole job either way.** A registry/prompt/record/dashboard diff is *ledger*, and +`PyAutoMind/.github/workflows/mind_ledger_merge.yml` merges a ledger-only +`claude/**` push into `main` and deletes the branch, unattended — no PR, and +nothing for the human to merge afterwards. Do not leave a Mind branch hanging, +and do not ask for it to be merged. + +The gate is default-deny and blocks on code: a push that also touches +`PyAutoMind/scripts/`, `tests/`, `.github/`, `skills/`, `policy/`, `docs/`, +`repos.yaml` or the prose pages waits for a human — say so rather than implying +the state landed. `python3 scripts/ledger_merge.py classify --base origin/main` +in the Mind checkout answers it before you push; the contract is +`PyAutoMind/REFERENCE.md` "How the ledger lands". + `active.md` task schema, the completion-record schema, and the prompt taxonomy (`draft/feature//`, `draft/bug//`, …) are documented in `PyAutoMind/README.md`. **Under `draft/`, the first folder is the work type, the diff --git a/skills/prm/prm.md b/skills/prm/prm.md index 9e2eae44..64036bef 100644 --- a/skills/prm/prm.md +++ b/skills/prm/prm.md @@ -172,8 +172,21 @@ Typing `/prm` authorized all of this; the only questions are the guards in step ``` Never hand-edit either page. Commit the render **with** the record, then - `lifecycle.py check` and push Mind on `main`. `git show --stat HEAD` must name - both dashboard files beside the record, or leg 3 did not happen. + `lifecycle.py check` and push Mind. `git show --stat HEAD` must name both + dashboard files beside the record, or leg 3 did not happen. + + **Push the branch you are on — never force `main`.** On a laptop that branch + *is* `main`. On a branch-scoped surface (the phone, claude.ai/code, any + `claude/**` flow) it is the session's branch, and pushing it is the whole + job: a close-out diff is ledger by construction, so + `mind_ledger_merge.yml` merges it into `main` and deletes the branch within + a minute — no PR, and no "merge that branch too" left for the human. Say in + the ledger that the Mind branch was pushed and will land itself. Two things + change that: the close-out also touched `scripts/`, `.github/`, `skills/` or + another code path (then the branch waits for a human — say so plainly), or + `lifecycle.py check` fails (then it was never going to merge; fix the drift). + `python3 scripts/ledger_merge.py classify --base origin/main` in the Mind + checkout tells you which of the three you are in. 5. **Worktree** — `worktree_remove `, never `rm -rf`. It refuses on a dirty repo and on a claim still registered in `active.md` — which is exactly why step 3 comes first. @@ -209,7 +222,9 @@ Stop and report instead of pressing on when: ## Notes - `/prm` merges an **existing** PR. No PR yet → `/ship_library` or - `/ship_workspace` first; `/prm` will say so rather than opening one. + `/ship_workspace` first; `/prm` will say so rather than opening one. The one + exception is Mind's own close-out commit, which needs no PR at all: pushing + the branch is what lands it (step 5.4). - It never bypasses the Heart readiness gate — that ran at ship time, and a red Heart is not something a merge shortcut may re-judge. Nor does merge ever stop being human: `/prm` is a human-typed door, never invoked by the `--auto` queue.