@jakkrichm/create-nexus-devflow 2.2.2 → 2.6.0

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.
Files changed (71) hide show
  1. package/README.md +58 -45
  2. package/dist/bin/create-nexus-devflow.js +9 -1
  3. package/dist/bin/create-nexus-devflow.js.map +1 -1
  4. package/dist/lib/command-catalog.js +1 -1
  5. package/dist/lib/command-catalog.js.map +1 -1
  6. package/dist/lib/core-skill-inventory.d.ts +16 -0
  7. package/dist/lib/core-skill-inventory.js +96 -0
  8. package/dist/lib/core-skill-inventory.js.map +1 -0
  9. package/dist/lib/dashboard-page.d.ts +1 -1
  10. package/dist/lib/dashboard-page.js +42 -20
  11. package/dist/lib/dashboard-page.js.map +1 -1
  12. package/dist/lib/dashboard-snapshot.js +16 -12
  13. package/dist/lib/dashboard-snapshot.js.map +1 -1
  14. package/dist/lib/dashboard.js +10 -1
  15. package/dist/lib/dashboard.js.map +1 -1
  16. package/dist/lib/doctor.js +14 -11
  17. package/dist/lib/doctor.js.map +1 -1
  18. package/dist/lib/gatekeeper.d.ts +4 -0
  19. package/dist/lib/gatekeeper.js +2 -2
  20. package/dist/lib/gatekeeper.js.map +1 -1
  21. package/dist/lib/git-status.d.ts +10 -2
  22. package/dist/lib/git-status.js +57 -29
  23. package/dist/lib/git-status.js.map +1 -1
  24. package/dist/lib/swarm-orchestrator.d.ts +4 -1
  25. package/dist/lib/swarm-orchestrator.js +2 -2
  26. package/dist/lib/swarm-orchestrator.js.map +1 -1
  27. package/dist/lib/update.js +5 -8
  28. package/dist/lib/update.js.map +1 -1
  29. package/dist/lib/version-check.js +1 -1
  30. package/dist/lib/workflow-state.js +19 -32
  31. package/dist/lib/workflow-state.js.map +1 -1
  32. package/dist/scripts/prepare-template.js +19 -16
  33. package/dist/scripts/prepare-template.js.map +1 -1
  34. package/package.json +1 -1
  35. package/template/.agents/skills/check/SKILL.md +78 -75
  36. package/template/.agents/skills/complete/SKILL.md +47 -36
  37. package/template/.agents/skills/debug/SKILL.md +76 -94
  38. package/template/.agents/skills/devflow/SKILL.md +51 -79
  39. package/template/.agents/skills/discovery/SKILL.md +7 -9
  40. package/template/.claude/skills/check/SKILL.md +78 -75
  41. package/template/.claude/skills/complete/SKILL.md +47 -36
  42. package/template/.claude/skills/debug/SKILL.md +76 -94
  43. package/template/.claude/skills/devflow/SKILL.md +51 -79
  44. package/template/.claude/skills/discovery/SKILL.md +7 -9
  45. package/template/AGENTS.md +21 -30
  46. package/template/devflow/build-plan.md +9 -0
  47. package/template/devflow/context/ai-interaction.md +43 -45
  48. package/template/devflow/context/coding-standards.md +31 -6
  49. package/template/devflow/context/current-stage.md +10 -7
  50. package/template/devflow/context/findings.md +8 -11
  51. package/template/devflow/context/glossary.md +31 -0
  52. package/template/devflow/history/HISTORY.md +1 -1
  53. package/template/devflow/project-plan.md +2 -2
  54. package/template/devflow/reference/build-plan-template.md +65 -0
  55. package/template/devflow/reference/feature-spec-template.md +110 -0
  56. package/template/devflow/reference/project-plan-template.md +128 -0
  57. package/template/devflow/reference/running-id-contract.md +12 -11
  58. package/template/.agents/skills/10-define/SKILL.md +0 -54
  59. package/template/.agents/skills/20-spec/SKILL.md +0 -155
  60. package/template/.agents/skills/30-plan/SKILL.md +0 -226
  61. package/template/.agents/skills/40-execute/SKILL.md +0 -158
  62. package/template/.agents/skills/50-verify/SKILL.md +0 -62
  63. package/template/.agents/skills/60-report/SKILL.md +0 -57
  64. package/template/.agents/skills/70-deliver/SKILL.md +0 -72
  65. package/template/.claude/skills/10-define/SKILL.md +0 -54
  66. package/template/.claude/skills/20-spec/SKILL.md +0 -155
  67. package/template/.claude/skills/30-plan/SKILL.md +0 -226
  68. package/template/.claude/skills/40-execute/SKILL.md +0 -158
  69. package/template/.claude/skills/50-verify/SKILL.md +0 -62
  70. package/template/.claude/skills/60-report/SKILL.md +0 -57
  71. package/template/.claude/skills/70-deliver/SKILL.md +0 -72
@@ -1,6 +1,7 @@
1
1
  import fs from "node:fs/promises";
2
2
  import path from "node:path";
3
3
  import { fileURLToPath } from "node:url";
4
+ import { loadCoreSkillInventory, shouldIncludeTemplatePath } from "../lib/core-skill-inventory.js";
4
5
  const __dirname = path.dirname(fileURLToPath(import.meta.url));
5
6
  const packageRoot = path.resolve(__dirname, "..");
6
7
  const repoRoot = path.resolve(packageRoot, "..", "..");
@@ -13,7 +14,7 @@ const entries = [
13
14
  "devflow",
14
15
  "LICENSE"
15
16
  ];
16
- async function copyEntry(entry) {
17
+ async function copyEntry(entry, inventory) {
17
18
  const source = path.join(repoRoot, entry);
18
19
  const target = path.join(templateRoot, entry);
19
20
  try {
@@ -21,6 +22,9 @@ async function copyEntry(entry) {
21
22
  recursive: true,
22
23
  filter: (src) => {
23
24
  const normalized = path.relative(repoRoot, src).replace(/\\/g, "/");
25
+ if (!shouldIncludeTemplatePath(normalized, inventory)) {
26
+ return false;
27
+ }
24
28
  if (normalized.startsWith("devflow/runs/") &&
25
29
  !normalized.endsWith(".gitkeep") &&
26
30
  !normalized.endsWith("README.md")) {
@@ -51,10 +55,6 @@ async function copyEntry(entry) {
51
55
  if (normalized.startsWith("devflow/research/")) {
52
56
  return false;
53
57
  }
54
- if (normalized.includes(".agents/skills/sync-upstream") ||
55
- normalized.includes(".claude/skills/sync-upstream")) {
56
- return false;
57
- }
58
58
  return true;
59
59
  }
60
60
  });
@@ -102,7 +102,7 @@ async function sanitizeStarterFiles() {
102
102
  // 2. Clean Starter HISTORY.md
103
103
  const starterHistory = `# Master Release History Ledger
104
104
 
105
- This master ledger tracks all released delivery runs, milestones, and rollbacks in chronological order. Each entry is recorded during \`/complete\` or \`70-deliver\` and links to its exact Git commit hash, release status, category, and archived delivery artifacts.
105
+ This master ledger tracks all released delivery runs, milestones, and rollbacks in chronological order. Each entry is recorded during \`/complete\` and links to its exact Git commit hash, release status, category, and archived delivery artifacts.
106
106
 
107
107
  ---
108
108
 
@@ -173,15 +173,17 @@ This master ledger tracks all released delivery runs, milestones, and rollbacks
173
173
  - Upcoming priorities, refactoring targets, or known technical considerations.
174
174
  `;
175
175
  await fs.writeFile(path.join(templateRoot, "devflow", "context", "project-overview.md"), starterOverview, "utf8");
176
- // 5. Clean Starter current-stage.md
177
- const starterStage = `# Current DevFlow Run Status
178
-
179
- - **Active Discovery ID**: \`None\`
180
- - **Active Running ID**: \`None\`
181
- - **Current Stage**: \`Idle (Ready for new /feature, /fix, /discovery, or /10-define)\`
182
- - **Living Spec**: \`None\`
183
- - **Last Completed Run**: \`None\`
184
- - **Last Updated**: \`None\`
176
+ const starterStage = `# Current Stage
177
+
178
+ - Active Discovery ID: \`None\`
179
+ - Active Running ID: \`None\`
180
+ - Track: \`idle\`
181
+ - Current Stage: \`idle\`
182
+ - Active Branch: \`main\`
183
+ - Living Spec: \`devflow/context/current-feature.md\`
184
+ - Next Action: \`Run /feature, /fix, or /discovery to start new work.\`
185
+ - Last Completed Run: \`None\`
186
+ - Last Updated: \`None\`
185
187
  `;
186
188
  await fs.writeFile(path.join(templateRoot, "devflow", "context", "current-stage.md"), starterStage, "utf8");
187
189
  // 6. Clean Starter current-feature.md
@@ -192,10 +194,11 @@ _Nothing in progress. Run /feature, /fix, or /rollback to start._
192
194
  await fs.writeFile(path.join(templateRoot, "devflow", "context", "current-feature.md"), starterFeature, "utf8");
193
195
  }
194
196
  async function main() {
197
+ const inventory = await loadCoreSkillInventory(path.join(repoRoot, "agent-bundle.manifest.json"));
195
198
  await fs.rm(templateRoot, { recursive: true, force: true, maxRetries: 5, retryDelay: 200 });
196
199
  await fs.mkdir(templateRoot, { recursive: true });
197
200
  for (const entry of entries) {
198
- await copyEntry(entry);
201
+ await copyEntry(entry, inventory);
199
202
  }
200
203
  await ensureEmptyDirectories();
201
204
  await sanitizeStarterFiles();
@@ -1 +1 @@
1
- {"version":3,"file":"prepare-template.js","sourceRoot":"","sources":["../../scripts/prepare-template.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,kBAAkB,CAAC;AAClC,OAAO,I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CAAC,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC,CAAC;IACtE,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;AAClB,CAAC,CAAC,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@jakkrichm/create-nexus-devflow",
3
- "version": "2.2.2",
3
+ "version": "2.6.0",
4
4
  "description": "Installer package for Nexus-DevFlow agentic workflow layer.",
5
5
  "license": "MIT",
6
6
  "author": "Jakkrich",
@@ -1,108 +1,111 @@
1
1
  ---
2
2
  name: check
3
- description: "[devflow][F] Prove the current work actually does what its spec says by running the real app and observing behavior against the \"done when\" criteria in current-feature.md. Drives the app (browser, CLI, or server), captures evidence (screenshots, output, console/network errors), and reports pass/fail per criterion. Does not edit source or commit - it observes; fixing stays /implement's job. Use when the user runs /check, asks to confirm a step or feature works, wants proof before /complete, or wants to check a change in the running app rather than just the build. (Supersedes the built-in /verify with a spec-aware version inside blueprint projects.)"
3
+ description: "[devflow][F] Prove the current work actually does what its spec says and adheres to architectural standards through a Dual-Axis Independent Review (Spec Fidelity + Standards & Architecture). Drives the app (browser, CLI, or server), captures empirical evidence (screenshots, output, console/network errors), checks against 12 Fowler smells and deep-module standards, and reports pass/fail. Does not edit source or commit - it observes; fixing stays /implement's job. Use when the user runs /check, asks to confirm a step or feature works, wants proof before /complete, or wants to check a change in the running app rather than just the build."
4
4
  ---
5
5
 
6
- # check - prove it works against the spec, with evidence
6
+ # check - Dual-Axis Independent Verification Engine
7
7
 
8
8
  Where this sits in the workflow:
9
9
 
10
10
  /implement -> [check] -> /complete
11
- (built a (run the app, (only once the
12
- step or prove each done-whens are
13
- the feature) done-when) proven)
11
+ (built a (dual-axis (only once both
12
+ step or review with axes pass with
13
+ the feature) empirical proof) evidence)
14
14
 
15
- `/implement` builds and does a quick build-plus-screenshot check inline. `/check`
16
- is the deeper, repeatable gate for when a "done when" needs the *real running app*,
17
- not just a green build: a click that triggers a download, a route that returns a
18
- file, a flow across screens. Run it on a single step whose done-when is
19
- behavioral, or on the whole feature as the acceptance check before `/complete`.
15
+ `/implement` builds and does a quick build-plus-screenshot check inline. `/check` is the rigorous, repeatable gate for when a feature or step needs **empirical proof** on the running app and **two-axis code review** before merging.
20
16
 
21
- The point is evidence. A passing build proves the code compiles; `/check` proves
22
- the thing the spec promised actually happens. It changes no source and commits
23
- nothing - it runs the app and reports what it saw.
17
+ It changes no source and commits nothing it executes, inspects, and reports observed facts.
18
+
19
+ ---
24
20
 
25
21
  ## Input
26
22
 
27
- Optional: a specific thing to check (a step, a flow, a URL). With no argument,
28
- verify the whole current feature against every "done when" in
29
- `devflow/context/current-feature.md`.
23
+ Optional: a specific target to check (a step, a flow, a URL). With no argument, verify the whole current feature against `devflow/context/current-feature.md` and `devflow/context/coding-standards.md`.
30
24
 
31
- ## Step 1 - build the checklist
25
+ ---
32
26
 
33
- Read `devflow/context/current-feature.md`. Pull the observable "done when"
34
- criteria from the build steps (and any acceptance notes in the Testing section).
35
- Turn them into a concrete checklist of claims to prove - each one a specific,
36
- observable behavior, not "it works". If the user named one thing, scope to that.
27
+ ## Step 1 - Build the Dual-Axis Review Matrix
37
28
 
38
- If there's no current feature spec, ask what to verify rather than guessing.
29
+ Read `devflow/context/current-feature.md` and `devflow/context/coding-standards.md`. Prepare the inspection criteria across two independent axes:
39
30
 
40
- ## Step 2 - get the app running
31
+ 1. **Axis 1 (Standards & Architecture Criteria)**:
32
+ - Coding conventions in `coding-standards.md`
33
+ - Deep Modules discipline (Small interface, deep implementation, clean seams, no leaky abstractions)
34
+ - Baseline 12 Fowler Code Smells (Primitive obsession, Feature envy, Shotgun surgery, Speculative generality, etc.)
35
+ - Multi-lane technical gates (Typecheck, test suites, zero secrets, zero P0/P1 findings)
36
+ 2. **Axis 2 (Spec Fidelity & Behavioral Observables)**:
37
+ - Line-by-line Acceptance Criteria (ACs) and "Done When" observables from `current-feature.md`
38
+ - Scope Creep detection (Unrequested behavior in the diff)
39
+ - Missing Requirements detection (Unimplemented edge cases)
41
40
 
42
- Use the project's real commands (see Commands in `AGENTS.md`). Match the project
43
- type:
41
+ ---
44
42
 
45
- - **Web app** - start (or reuse) the dev/preview server, then drive a real browser
46
- to the relevant routes. Prefer reusing an already-running server over starting a
47
- duplicate. If Playwright is already installed or declared in `AGENTS.md`, prefer
48
- it for browser driving, screenshots, console errors, and failed request checks.
49
- If it is not installed, do not add it from `/check`; use another real-browser
50
- evidence path and report what you used.
51
- - **CLI** - run the actual command(s) with representative inputs.
52
- - **Server/API** - start it and hit the endpoints.
53
- - **Library** - exercise the public API through an example or the test command.
43
+ ## Step 2 - Get the App Running & Exercise Live Proof
54
44
 
55
- If a `test` command is declared in `AGENTS.md`, you may run it as *one* input, but
56
- `/check` is broader than unit tests: it checks real behavior, which is exactly the
57
- evidence UI and integration steps ride on instead of unit tests.
45
+ Use the project's real commands (from `AGENTS.md`):
58
46
 
59
- ## Step 3 - exercise each claim
47
+ - **Web app**: Start (or reuse) the local dev server. Drive a real browser to relevant routes. Prefer Playwright when installed for screenshots, network errors, and console assertions.
48
+ - **CLI**: Execute commands with representative input fixtures, asserting exit codes and output snapshots.
49
+ - **Server / API**: Hit endpoints with real payloads and assert on HTTP response status and bodies.
50
+ - **Library**: Exercise public interfaces through integration tests or sample scripts.
60
51
 
61
- Drive the app to each checklist item and capture evidence as you go:
52
+ > [!IMPORTANT]
53
+ > **Evidence or it didn't happen**: Every verdict must be backed by empirical evidence (screenshot, command output, status code, response time). Never assume a pass from reading source code alone.
62
54
 
63
- - Navigate and interact for real (click, type, submit, download) - don't assert
64
- from the code what the running app would do.
65
- - Capture **screenshots** for visual/UI claims, **output** for CLI/API claims.
66
- - Watch for **console errors and failed network requests**; a clean-looking screen
67
- with errors in the console is not a pass.
55
+ ---
68
56
 
69
- ## Step 4 - report (Two-Stage Review Pattern)
57
+ ## Step 3 - Dual-Axis Independent Report
70
58
 
71
- Format the verification report into two explicit review stages:
59
+ Format the report into two distinct, un-merged review axes:
72
60
 
73
- ### Stage 1: Spec Fidelity & Acceptance Gate
74
- Give a line-by-line verdict for each Acceptance Criterion and "done when" item:
61
+ ```markdown
62
+ # 🔍 Verification Report: [Feature Name]
75
63
 
76
- [pass] AC-1: Download PDF saves certificate-<slug>.pdf - file downloaded, opened to cert
77
- [pass] AC-2: Both buttons show a loading state - screenshot: loading-state.png
78
- [fail] AC-3: PDF border missing - printBackground not set; screenshot: pdf-no-border.png
79
- [skip] AC-4: Vercel deploy smoke test - can't verify locally (pending staging)
64
+ ## ⚖️ Axis 1: Standards, Architecture & Quality Gate
80
65
 
81
- ### Stage 2: Code Quality, Security & Architecture Gate
82
- Report the multi-lane technical verification results:
83
- - **Type & Syntax**: `tsc --noEmit` (0 errors)
84
- - **Automated Tests**: Unit & integration tests (100% pass)
85
- - **Security & Hygiene**: Zero secrets, sanitized inputs
86
- - **Findings Ledger**: 0 blockers (P0/P1) in `devflow/context/findings.md`
66
+ - **Technical Lanes**:
67
+ - [pass] Type Safety: `tsc --noEmit` (0 errors)
68
+ - [pass] Automated Tests: `npm test` (All tests green)
69
+ - [pass] Security & Hygiene: Zero secrets, sanitized inputs
70
+ - [pass] Findings Ledger: 0 blocking P0/P1 in `devflow/context/findings.md`
71
+ - **Deep Modules & Architecture**:
72
+ - [pass] Seam Integrity: Public interfaces remain small, implementation details hidden.
73
+ - [pass] The Deletion Test: Complexity is concentrated inside the module, not scattered across callers.
74
+ - **Code Smells Assessment**:
75
+ - [clean] 12 Fowler Code Smells evaluated across git diff: No critical smells detected.
87
76
 
88
- ### Final Verdict & Route
89
- - **All Passed**: State that the feature is verified and ready for `/complete`.
90
- - **Any Failure**: Hand back to `/implement` with exact failure evidence and reproduction steps. Never fix issues inside `/check`.
91
- - **Unverifiable**: Clearly state reasons and residual risk. Never fabricate a pass.
77
+ ## 🎯 Axis 2: Spec Fidelity & Behavioral Acceptance Gate
92
78
 
93
- ## Rules
79
+ Line-by-line verification against `current-feature.md`:
80
+ - [pass] **AC-1 (<title>)**: <Observed empirical evidence / screenshot path>
81
+ - [pass] **AC-2 (<title>)**: <Observed empirical evidence / terminal output>
82
+ - [fail] **AC-3 (<title>)**: <Exact observed failure with reproduction command>
83
+ - [clean] **Scope Creep Check**: No unrequested features or unnecessary abstractions introduced.
84
+ - [clean] **Completeness Check**: 100% of spec requirements addressed.
85
+
86
+ ---
87
+
88
+ ## 🚦 Final Routing & Verdict
94
89
 
95
- - **Observe, don't change.** `/check` runs the app and reports. It never edits
96
- source, never commits, never merges. Fixing is `/implement`'s job.
97
- - **Evidence or it didn't happen.** Every `pass` is backed by something observed -
98
- a screenshot, output, a response. No assumed passes from reading the code.
99
- - **Honest over green.** "Couldn't verify" and "failed" are valid, useful results.
100
- Faking a pass defeats the entire gate.
101
- - **Check the spec, not vibes.** Verify against the done-whens in
102
- `current-feature.md`, so "works" means what the spec said it would do.
90
+ - **ALL PASSED**: Both axes green. Ready for `/complete`.
91
+ - **ANY FAILURE**: Hand back to `/implement` with exact failure evidence and reproduction steps.
92
+ - **UNVERIFIABLE**: Clearly document the gap and residual risk. Never fabricate a pass.
93
+ ```
103
94
 
104
- ## Formatting
95
+ ---
96
+
97
+ ## Why Two Independent Axes?
98
+
99
+ A code change can pass one axis and fail the other:
100
+ - **Standards Pass, Spec Fail**: Code is beautifully architected and tested, but implements the wrong business behavior.
101
+ - **Spec Pass, Standards Fail**: Feature works end-to-end, but violates encapsulation, introduces shallow modules, or leaks secrets.
102
+
103
+ Reporting both axes side-by-side stops elegance from masking functional bugs, and stops functional completeness from excusing architectural rot.
104
+
105
+ ---
106
+
107
+ ## Rules
105
108
 
106
- Format the output to match the project's conventions in
107
- `devflow/context/ai-interaction.md`: concise, scannable markdown, with lists for
108
- enumerations and tables for matrices rather than dense paragraphs.
109
+ - **Observe, don't change**: `/check` runs the app and reports. It never edits source or commits. Fixing is `/implement`'s job.
110
+ - **Honest over green**: "Failed" and "Could not verify" are valid, valuable outputs. Faking a pass destroys the gate.
111
+ - **Check the spec, not vibes**: Verify against documented ACs, not subjective feelings.
@@ -1,18 +1,18 @@
1
1
  ---
2
2
  name: complete
3
- description: "[devflow][F] Wrap up a finished feature, fix, or rollback. Runs a final safety pass, archives its spec to devflow/history/features/, devflow/history/fixes/, or devflow/history/rollbacks/, updates the build plan for features and rollbacks, resets devflow/context/current-feature.md to its stub, makes one work-level commit, then squash-merges the branch to main and deletes it. Merges only with explicit approval, then asks separately before pushing main. Use when the user runs /complete, or asks to finish, wrap up, merge, or close out the current feature, fix, or rollback after it is built and reviewed."
3
+ description: "[devflow][F] Wrap up a finished feature, fix, or rollback. Runs a final safety pass, archives its spec to devflow/history/features/, devflow/history/fixes/, or devflow/history/rollbacks/, updates the build plan for features and rollbacks, resets devflow/context/current-feature.md to its stub, and makes the work commit. Enforces a mandatory user gate: asks whether to squash-merge to main/master OR pull latest main/master into the feature/dev branch and push to remote for Merge Request (MR / PR) creation. Never merges into main/master without explicit user instruction."
4
4
  ---
5
5
 
6
- # complete - log the finished work, make the work commit, and merge
6
+ # complete - log the finished work, make the work commit, and deliver
7
7
 
8
8
  Where this sits in the workflow:
9
9
 
10
10
  /feature, /fix, or /rollback -> /implement -> [complete] -> next
11
- (the spec) (build it) (commit + merge + log)
11
+ (the spec) (build it) (commit + delivery gate)
12
12
 
13
13
  `/implement` built the feature, fix, or rollback on its branch, with optional per-step commit
14
14
  checkpoints. This skill closes it out: it logs the work, makes the single
15
- work-level commit, and squash-merges. Run it only when the work is done,
15
+ work-level commit, and guides the delivery through a **Mandatory User Delivery Gate**. Run it only when the work is done,
16
16
  reviewed, and the documented `Verify` command, or the fallback build and tests,
17
17
  passes.
18
18
 
@@ -22,7 +22,7 @@ Confirm the work is actually finished: `devflow/context/current-feature.md`
22
22
  holds a real spec, its steps are built on a branch, and `Verify`, or the fallback
23
23
  build and tests, passes. If any of the
24
24
  spec's done-whens are behavioral, `/check` should have proven them against the
25
- running app first - don't merge on an unverified claim. Uncommitted step work is
25
+ running app first - don't merge or complete on an unverified claim. Uncommitted step work is
26
26
  expected (per-step checkpoints are optional); this skill commits it. Don't require
27
27
  the steps to be pre-committed.
28
28
 
@@ -30,7 +30,7 @@ the steps to be pre-committed.
30
30
 
31
31
  Before logging or committing, run a short safety pass and report blockers only:
32
32
 
33
- - active spec exists and the work is not being completed from `main` or `master`
33
+ - active spec exists and the work is not being completed directly from `main` or `master`
34
34
  - changed files are tied to the active spec, with no unrelated dirty work mixed
35
35
  in (a dirty `devflow/context/findings.md` is expected, since `/audit` writes it)
36
36
  - the exact `Verify` command from `AGENTS.md` passed in this session, when one is
@@ -107,25 +107,47 @@ into the app - delete the `prototypes/` folder now. The tokens live in the real
107
107
  stylesheet and the HTML mockups were always throwaway; fold the deletion into this
108
108
  feature's commit. Skip this if the feature didn't consume prototypes.
109
109
 
110
- ## Step 2 - make the work commit
110
+ ## Step 2 - make the work commit on feature branch
111
111
 
112
112
  Stage everything on the branch (any uncommitted step work plus the Step 1 logging
113
- changes) and make one conventional work commit (for example `feat: <feature>`,
113
+ changes) and make one conventional work commit on the active branch (for example `feat: <feature>`,
114
114
  `fix: <name>`, or `revert: roll back <feature>`). `Verify`, or the fallback build
115
115
  and tests, must pass first.
116
116
 
117
- ## Step 3 - merge
117
+ ## Step 3 - Mandatory Delivery Gate (Ask User First)
118
+
119
+ > [!IMPORTANT]
120
+ > **MANDATORY USER SELECTION**: In real-world engineering teams, developers often do NOT have direct merge/push access to `main` or `master` (protected branches).
121
+ > Therefore, you **MUST STOP AND ASK** the user to choose their desired delivery flow. **NEVER automatically merge into `main` or `master` without explicit user choice.**
122
+
123
+ Present the user with two clear delivery options:
124
+
125
+ ### 🔀 Option 1: Team MR / PR Flow (Pull latest main/master & Push dev branch) [Default for Teams]
126
+ - **When to choose**: When working in a team where code reviews happen via GitLab Merge Request (MR) or GitHub Pull Request (PR), or where developers lack direct write access to protected `main`/`master` branches.
127
+ - **Execution Actions**:
128
+ 1. Detect default base branch name (`main` or `master`).
129
+ 2. Run `git pull origin <main/master>` (or `git fetch origin <main/master> && git merge origin/<main/master>`) to bring the latest upstream changes into the active feature/dev branch.
130
+ 3. If merge conflicts occur, highlight them clearly and help the user resolve them.
131
+ 4. Run `Verify` (or build & tests) to ensure integrity after the merge.
132
+ 5. Run `git push origin <current-feature-branch>` to push the up-to-date branch to the remote repository.
133
+ 6. Stop and inform the user that the branch is synchronized and pushed, ready for them to open a Merge Request (MR / PR) on GitLab/GitHub.
134
+ 7. **Do NOT merge into local `main`/`master` and do NOT delete the branch.**
135
+
136
+ ### 🔀 Option 2: Direct Local Squash-Merge (Solo / Direct Access Mode)
137
+ - **When to choose**: Only when the user explicitly instructs that they want to merge directly into `main` or `master` locally now (e.g. solo projects or Tech Leads with merge privileges).
138
+ - **Execution Actions**:
139
+ 1. Switch to `main` or `master`: `git checkout <main/master>`.
140
+ 2. Squash-merge the branch: `git merge --squash <feature-branch>`.
141
+ 3. Commit the squash-merge.
142
+ 4. Delete the local feature branch only with the user's explicit consent.
143
+ 5. **Stop and ask separately** before pushing local `main`/`master` to remote upstream. The merge approval does NOT count as push approval.
144
+ 6. Run `git push origin <main/master>` only after separate explicit confirmation.
118
145
 
119
- 1. Squash-merge the branch into main, only with the user's explicit go-ahead, so
120
- the feature lands as one clean commit regardless of how many checkpoints the
121
- branch carried.
122
- 2. Delete the branch after a clean merge.
123
- 3. Stop and ask whether to push local `main` to its upstream. The merge approval
124
- does not count as push approval.
125
- 4. Push main only after a separate explicit yes to push main in the current chat.
126
- If the repo has no remote or upstream, say so instead of guessing.
146
+ ---
147
+
148
+ ## Step 4 - Finish & Try Path
127
149
 
128
- Then point the user at `/feature`, `/fix`, or `/rollback` for the next thing.
150
+ Point the user at `/feature`, `/fix`, or `/rollback` for the next task.
129
151
 
130
152
  Finish with a concise **How to try it** note for the completed work. For a
131
153
  rollback, explain how to confirm the removed behavior is gone and name one
@@ -135,26 +157,15 @@ that command can read the archived feature after `current-feature.md` is reset.
135
157
 
136
158
  ## Rules
137
159
 
160
+ - **Mandatory User Confirmation Gate**: Always ask before choosing between Team MR/PR Push vs Direct Squash-Merge.
161
+ - **Never auto-merge into main/master**: The decision to merge into `main` or `master` belongs strictly to the user.
138
162
  - The work item is the unit of history: one squashed feature, fix, or rollback
139
- commit on main, even if the branch carried several checkpoint commits.
163
+ commit, even if the branch carried several checkpoint commits.
140
164
  - A rollback preserves the original feature archive and adds a separate rollback
141
165
  archive. Never rewrite history to make the feature look as if it never existed.
142
- - Don't merge unfinished or failing work. The documented `Verify` command, or
166
+ - Don't merge or push unfinished or failing work. The documented `Verify` command, or
143
167
  the fallback build and tests, must pass first.
144
- - Never merge while a P0 or P1 finding is `open` or `fixed` in the ledger. The
145
- recorded ways past the gate without code are `accepted` (only by the user's
146
- explicit decision, with their reason) or `invalid` (only from re-examination
147
- evidence or the user's explicit call); both travel into the archive, never a
148
- silent drop.
149
- - Merging and pushing are the user's calls: get an explicit yes for the merge,
150
- then ask whether to push main. Do not treat merge approval, `/complete`, or
151
- "looks good" as permission to push.
152
- - Push main only after a separate explicit yes to push main in the current chat.
168
+ - Never merge or push while a P0 or P1 finding is `open` or `fixed` in the ledger.
169
+ - Pushing to remote is always explicit: confirm before running `git push`.
153
170
  - One item per completion. If a parent feature still has unchecked sub-features,
154
- leave the parent unchecked.
155
-
156
- ## Formatting
157
-
158
- Format the output to match the project's conventions in
159
- `devflow/context/ai-interaction.md`: concise, scannable markdown, with lists for
160
- enumerations and tables for matrices rather than dense paragraphs.
171
+ leave the parent unchecked.