@seanyao/roll 3.608.1 → 3.609.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@seanyao/roll",
3
- "version": "3.608.1",
3
+ "version": "3.609.2",
4
4
  "description": "Roll — Roll out features with AI agents",
5
5
  "packageManager": "pnpm@11.1.3",
6
6
  "scripts": {
@@ -233,7 +233,7 @@ Wait for the user's response before editing files. If the user does not object w
233
233
 
234
234
  - Use `$roll-design` to split vague request into INVEST-compliant User Stories
235
235
  - Insert US into `.roll/backlog.md` under the relevant Epic > Feature group
236
- - If a new story folder is needed, create `.roll/features/<epic>/<story>/spec.md` (with `roll idea` or manually)
236
+ - If a new story folder is needed, mint it via `roll story new <ID> --title <t> --epic <e>` (the single channel, US-META-009), then edit the spec
237
237
 
238
238
  After creation, switch to **Story mode** and execute the first US immediately.
239
239
 
@@ -497,16 +497,19 @@ the full diff as a single-pass fallback — do not skip review entirely.
497
497
  🟢 Suggestions / ✅ All clear → Proceed to Phase 8
498
498
  ```
499
499
 
500
- ### Phase 8: Commit & Push
500
+ ### Phase 8: Commit & Push (branch + PR — NEVER direct to main)
501
501
 
502
- ```bash
503
- # All TCR micro-commits are already made
504
- # Squash or keep as-is based on repo convention
505
-
506
- git log --oneline -{n} # Review TCR commits
502
+ `main` is PR-protected. Push the worktree's branch and open a PR — never
503
+ `git push origin main`. (When invoked by `roll-loop`, the runner already
504
+ created the worktree + branch and opens the PR; this is the manual-path
505
+ equivalent.)
507
506
 
508
- git pull origin main --rebase
509
- git push origin main
507
+ ```bash
508
+ # All TCR micro-commits are already made on the worktree's branch (Phase 0).
509
+ git log --oneline -{n} # Review TCR commits
510
+ git push -u origin <branch> # the dispatch/<id> branch from Phase 0
511
+ gh pr create --title "{story-id}: …" --body "…"
512
+ # After CI is green: gh pr merge --rebase
510
513
  ```
511
514
 
512
515
  Commit message (if squashing):
@@ -727,6 +730,15 @@ Before creating any file or directory:
727
730
 
728
731
  ## Hard Rules
729
732
 
733
+ 0. **Worktree-first, PR-at-end (ALWAYS)**
734
+ Before writing any code, work in a dedicated git worktree on its own
735
+ branch (`git worktree add ../wt-<id> -b <branch>`), never in the shared
736
+ checkout — so concurrent cycles / sessions never collide. Finish by
737
+ pushing the branch and opening a PR; `main` is PR-protected — NEVER
738
+ `git push origin main`. (Under `roll-loop` the runner creates the
739
+ worktree + branch and opens the PR; this rule is the manual-path
740
+ equivalent and must hold either way.)
741
+
730
742
  1. **No local-only "done"**
731
743
  Work is not complete until it reaches:
732
744
  commit → push → CI signal → deploy → online verification → backlog update
@@ -782,7 +794,7 @@ Before creating any file or directory:
782
794
  ### Self-score (US-SKILL-012)
783
795
 
784
796
  Before reporting completion to the user, write one self-score note. The
785
- helper lands the note under `.roll/notes/<date>-roll-build-<US-id>-<epoch>.md`
797
+ helper lands the note under `.roll/features/<epic>/<US-id>/notes/<date>-roll-build-<US-id>-<epoch>.md` (the card folder is the note home, US-META-008; resolve <epic> via .roll/index.json)
786
798
  with YAML frontmatter so trend analysis (US-SKILL-014) can aggregate later:
787
799
 
788
800
  ```bash
@@ -132,8 +132,9 @@ Document structure (story-first layout, US-META-005):
132
132
 
133
133
  **File path resolution:**
134
134
  1. Determine epic from story ID prefix (e.g., US-META-* → backlog-lifecycle, FIX-* → query index.json)
135
- 2. Create story folder: `.roll/features/<epic>/<story>/`
136
- 3. Write spec.md: `.roll/features/<epic>/<story>/spec.md` (full AC + details)
135
+ 2. Mint the card via the single channel (US-META-009 — never hand-create the folder):
136
+ `roll story new <ID> --title "<one-line title>" --epic <epic>`
137
+ 3. Then EDIT the minted spec.md to add the full AC / Files / Dependencies / Agent profile
137
138
  4. Backlog row links to: `.roll/features/<epic>/<story>/spec.md`
138
139
  5. Design / plan docs (when needed): `.roll/features/<epic>/<feature>.md` + `<feature>-plan.md`
139
140
 
@@ -48,6 +48,14 @@ Before creating any file or directory:
48
48
 
49
49
  ## Hard Rules
50
50
 
51
+ 0. **Worktree-first, PR-at-end (ALWAYS)**
52
+ Before editing, work in a dedicated git worktree on its own branch
53
+ (`git worktree add ../wt-<id> -b <branch>`), never the shared checkout —
54
+ concurrent cycles/sessions must not collide. Finish by pushing the branch
55
+ and opening a PR; `main` is PR-protected — NEVER `git push origin main`.
56
+ (Under `roll-loop` the runner handles the worktree + PR; this rule is the
57
+ manual-path equivalent and holds either way.)
58
+
51
59
  1. **No local-only "done"**
52
60
  Even for a minor change, the work is not complete until it reaches:
53
61
  - TCR micro-commits (test-guaranteed working states)
@@ -276,14 +284,17 @@ $roll-.review staged
276
284
 
277
285
  **Note:** `code-reviewer` placeholder replaced with `$roll-.review` for local execution.
278
286
 
279
- ### 7. Commit and push
287
+ ### 7. Commit and push (branch + PR — NEVER direct to main)
280
288
 
281
- ```bash
282
- # TCR commits already made during implementation
283
- # May squash or keep micro-commits based on repo convention
289
+ `main` is PR-protected. Push the worktree's branch and open a PR — never
290
+ `git push origin main`. (Under `roll-loop` the runner already made the
291
+ worktree + branch and opens the PR; this is the manual-path equivalent.)
284
292
 
285
- git pull origin main --rebase
286
- git push origin main
293
+ ```bash
294
+ # TCR commits already made on the worktree's branch (see Hard Rule 0).
295
+ git push -u origin <branch>
296
+ gh pr create --title "{fix|hotfix}: …" --body "…"
297
+ # After CI is green: gh pr merge --rebase
287
298
  ```
288
299
 
289
300
  Commit message:
@@ -500,7 +511,7 @@ A minor change is only "done" when all are true:
500
511
  ### Self-score (US-SKILL-011)
501
512
 
502
513
  Before exiting the cycle, write one self-score note. The helper validates
503
- inputs and lands the note under `.roll/notes/<date>-roll-fix-<FIX-id>-<epoch>.md`:
514
+ inputs and lands the note under `.roll/features/<epic>/<FIX-id>/notes/<date>-roll-fix-<FIX-id>-<epoch>.md` (the card folder is the note home, US-META-008; resolve <epic> via .roll/index.json):
504
515
 
505
516
  ```bash
506
517
  bash -c 'source "$(command -v roll)"; \