@haus-tech/haus-workflow 5.4.0 → 5.5.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.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,15 @@
1
1
  # Changelog
2
2
 
3
+ ## [5.5.0](https://github.com/WeAreHausTech/haus-workflow/compare/v5.4.0...v5.5.0) (2026-09-12)
4
+
5
+ ### Features
6
+
7
+ - **haus-workflow:** PoC mode in project:new ([#555](https://github.com/WeAreHausTech/haus-workflow/issues/555)) ([ffd2bfa](https://github.com/WeAreHausTech/haus-workflow/commit/ffd2bfa7e34bd66f679d23df3e54868b7536d291))
8
+
9
+ ### Bug Fixes
10
+
11
+ - **poc:** two gaps the acceptance run found ([#556](https://github.com/WeAreHausTech/haus-workflow/issues/556)) ([728fe3b](https://github.com/WeAreHausTech/haus-workflow/commit/728fe3bc88fe31f1e6189c62108c89fbbe5d86d3))
12
+
3
13
  ## [5.4.0](https://github.com/WeAreHausTech/haus-workflow/compare/v5.3.0...v5.4.0) (2026-09-12)
4
14
 
5
15
  ### Features
package/dist/cli.js CHANGED
@@ -9557,14 +9557,14 @@ async function runDoctor(options) {
9557
9557
  ok(`- .prettierignore: protects ${IGNORED_PATHS.join(" and ")}`);
9558
9558
  }
9559
9559
  }
9560
- if (!await projectRunsCiGate(root)) {
9560
+ if (await projectRunsCiGate(root)) {
9561
+ ok("- CI GATE: OK (a workflow runs `haus ci-gate`)");
9562
+ } else if (PROFILES[profile].writesCiGate) {
9561
9563
  suggest(
9562
9564
  `- CI GATE: missing \u2014 no workflow runs \`haus ci-gate\` (${CI_GATE_WORKFLOW_REL})`,
9563
9565
  "Nothing checks this project on a pull request: setup drift, a missing ADR, or a stale catalog would all land unnoticed",
9564
9566
  "haus apply --write (writes .github/workflows/haus-gate.yml; never overwrites an existing one)"
9565
9567
  );
9566
- } else {
9567
- ok("- CI GATE: OK (a workflow runs `haus ci-gate`)");
9568
9568
  }
9569
9569
  if (!PROFILES[profile].writesCiGate) {
9570
9570
  const ciGateContent = await readText(path49.join(root, CI_GATE_WORKFLOW_REL));
@@ -29,7 +29,7 @@ that branch of the merged task.
29
29
  | --------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
30
30
  | `init` (`setup`, `project:init`, `reinit`, `re-init`, `project:reinit`) | _Init procedure below_ | State-aware setup. Not set up → first-time init (skills, commands, workflow + project docs). Already set up → asks: non-destructive refresh, or clean slate (confirmed wipe via `haus undo --yes` / `haus workspace undo`, then re-init). `reinit` aliases jump straight to the clean-slate branch (still confirmed). |
31
31
  | `clone [name]` (`project:clone`, `cloneandsetup`, `project:cloneandsetup`) | _Clone procedure below_ | Clone one repo by name, or a whole workspace from `repos.manifest.json`. Afterwards asks "set up for local dev too?" (deps, databases, links, env via `localdev.yml`). `cloneandsetup` aliases pre-answer that question with yes. |
32
- | `new [description]` (`create`, `project:new`) | _New-project procedure below_ | Create a brand-new project from a plain-language request — unchanged seven-phase flow. |
32
+ | `new [description]` (`create`, `project:new`, `poc`, `kunddemo`) | _New-project procedure below_ | Create a brand-new project from a plain-language request, unchanged seven-phase flow. The `poc`/`kunddemo` aliases (and phrases like "ny poc", "customer demo") run the same flow in PoC mode: a throwaway demo repo under the `poc` profile (`--profile poc`), see `references/new.md` → PoC mode. |
33
33
  | `doctor` (`check`, `fix`, `project:doctor`, `project:fix`) | _Doctor procedure below_ | Health check for the detected scope; relays the verdict, then offers to apply the doctor's own suggested fixes and re-checks until green. `fix` aliases pre-answer "fix now?" with yes. |
34
34
  | `refresh` (`update`, `upgrade`, `apply`, `regenerate`, `claude-md`, `project:refresh`, `add-skills`, `opt-in`, `project:add-skills`, `install`, `global`) | _Refresh procedure below_ | Bring haus current. Always: update npm package + catalog + `~/.claude` (seeding it first if never installed). Inside a set-up project/workspace, asks: **Full sync** (re-run the whole setup pipeline in place) or **Just add helpers** (offer opt-in skills/agents + configs only). `add-skills`/`opt-in` aliases jump to the helpers branch; outside any project it stops after the global update. |
35
35
  | `uninstall` | `haus uninstall` | Remove all haus global files from `~/.claude/`. Machine scope only — confirm gate states this does NOT touch the current project (that's `init` → clean slate). |
@@ -52,7 +52,7 @@ into a single `AskUserQuestion` call:
52
52
  Question 1: "What would you like to do?"
53
53
  Options:
54
54
  1. init — set up this project (or workspace) with haus; offers refresh/clean-slate when already set up
55
- 2. new [description] — create a brand-new project from a plain-language request
55
+ 2. new [description] — create a brand-new project, or a throwaway PoC, from a plain-language request
56
56
  3. refresh — update haus itself, then fully sync this project (or just add optional helpers)
57
57
  4. More options — see: clone, doctor, uninstall, help
58
58
 
@@ -211,7 +211,7 @@ Bring haus current. Global half always runs; the project half depends on scope.
211
211
  it must ask the workspace-membership question there before eliciting anything
212
212
  else. Otherwise (Project or Not-set-up scope) open it knowing that question is
213
213
  skipped.
214
- 2. Open and follow `references/new.md` in this skill's directory. It is a seven-phase AI-driven flow: elicit the request and propose features, gate on user intent, scaffold (registry stacks via `haus new --json --yes` with a `--dry-run` preview; any other stack via a user-confirmed official scaffolder plus manual rails), install context via `haus init`, seed `docs/SPEC.md` + `docs/plans/walking-skeleton.md`, build the walking skeleton with one subagent per feature (against a structure recorded in `docs/DESIGN.md`), verify (build + lint + tests + smoke boot), then write the project docs by following `references/init.md` from step 3 (deep read, `CLAUDE.md` body + `docs/`, recommend re-check, opt-ins). Repos are only ever created private. Failure `detail` is relayed verbatim and nothing is ever auto-deleted. Never run bare interactive `haus new`.
214
+ 2. Open and follow `references/new.md` in this skill's directory. It is a seven-phase AI-driven flow: elicit the request and propose features, gate on user intent, scaffold (registry stacks via `haus new --json --yes` with a `--dry-run` preview; any other stack via a user-confirmed official scaffolder plus manual rails), install context via `haus init`, seed `docs/SPEC.md` + `docs/plans/walking-skeleton.md`, build the walking skeleton with one subagent per feature (against a structure recorded in `docs/DESIGN.md`), verify (build + lint + tests + smoke boot), then write the project docs by following `references/init.md` from step 3 (deep read, `CLAUDE.md` body + `docs/`, recommend re-check, opt-ins). Repos are only ever created private. Failure `detail` is relayed verbatim and nothing is ever auto-deleted. Never run bare interactive `haus new`. The same reference carries a **PoC mode** (entered by the `poc`/`kunddemo` aliases, or by the "Production project or throwaway PoC?" question when no phrase was given): the repo gets the `poc` profile before the first design question (`haus new --profile poc` on the fast path; a hand-written `haus.config.json` plus `haus init --json --dry-run --profile poc` and `haus apply --write` on the manual path), the first brainstorm writes `docs/MANUS.md` instead of `docs/SPEC.md`, the only check is the Playwright manus, and Phase 6 skips the docs pass.
215
215
 
216
216
  ### After `haus uninstall`
217
217
 
@@ -8,6 +8,43 @@ session, from request to running app.
8
8
  NEVER run bare `haus new` without flags — its interactive prompts don't work through
9
9
  the agent; collect answers with AskUserQuestion and pass everything as flags.
10
10
 
11
+ ## PoC mode
12
+
13
+ The same seven phases, for a throwaway proof of concept or customer demo (haus-workflow
14
+ ADR-0125, catalog ADR-0066). Enter it when the request says `new poc`, `poc`, `ny poc`,
15
+ `kunddemo`, `customer demo` or `throwaway demo`. With no such phrase, ask via
16
+ `AskUserQuestion` before Phase 0 runs its own checks: "Production project or throwaway PoC?"
17
+ The answer decides the mode for the rest of the flow, so by the time Phase 0 starts,
18
+ the mode is always known, either from the trigger phrase or from this question.
19
+ Production mode is everything below without the **PoC:** paragraphs.
20
+
21
+ What PoC mode changes, in one place:
22
+
23
+ - The project gets the `poc` profile (`--profile poc`) BEFORE the first design
24
+ question. The profile writes the PoC standard as `.haus-workflow/WORKFLOW.md`, keeps
25
+ testing/review/security content out, writes no CI gate. Once it is in place, every
26
+ rule the rest of this flow needs is already loaded.
27
+ - No feature elicitation. The first superpowers brainstorming round IS the design; its
28
+ output is `docs/MANUS.md` (the demo script), not `docs/SPEC.md`. No `docs/DESIGN.md`,
29
+ no walking-skeleton plan, no docs pass.
30
+ - The only executable check is `demo/manus.spec.ts`, one Playwright test per manus
31
+ point. No unit tests, no TDD, no code review. `.haus-workflow/WORKFLOW.md` in the new
32
+ repo says the same and is authoritative from Phase 5 on.
33
+ - The repo is always private and is archived after the demo. The demo date is written
34
+ into `docs/MANUS.md` (`Demo: YYYY-MM-DD`); "where are we" reports days left.
35
+
36
+ Two ways into the repo, decided in Phase 0 by what the cwd is:
37
+
38
+ - **The cwd is the project** (an empty directory, or a git repo): the manual rails
39
+ below scaffold into `.`; a repo with a remote is used as is, a repo without one is
40
+ pushed to a new private GitHub repo after asking where, or kept local only if that is
41
+ the answer.
42
+ - **The cwd is a parent folder** (anything else): the registry fast path
43
+ `haus new <stack> <name> --json --yes --profile poc [--dir <path>] [--org <org>]
44
+ [--no-github]` creates `<cwd>/<name>` (or `<path>/<name>` when `--dir` is given, e.g.
45
+ the workspace root from Phase 0), local only when that is the Phase 1 answer; the
46
+ handoff tells the user to open that directory as a new Claude Code project.
47
+
11
48
  ## Phase 0 — Entry
12
49
 
13
50
  **Scope check first.** If `SKILL.md`'s Step 1.5 found the cwd is **Workspace** scope (or
@@ -30,6 +67,14 @@ A description argument ("a frontend app for shopping") goes straight to Phase 1.
30
67
  No-argument invocation: ask "What do you want to build?" as free text. Do not present
31
68
  a stack menu.
32
69
 
70
+ **PoC:** the mode is already settled by now, either the trigger phrase in the request or
71
+ the question asked in `## PoC mode` above, so decide the way in next: `git rev-parse
72
+ --is-inside-work-tree` and `ls -A`: an empty directory or a git repo means the cwd IS the
73
+ project (manual rails in Phase 3); anything else means the cwd is a parent folder (fast
74
+ path). A git repo with a remote (`git remote -v`) keeps it; one without gets a new
75
+ private repo in Phase 3, unless local-only is chosen in Phase 1. The workspace question
76
+ above applies unchanged.
77
+
33
78
  ## Phase 1 — Elicit (at most 5 AskUserQuestion rounds)
34
79
 
35
80
  Ask about dimensions, never from a domain template:
@@ -48,6 +93,19 @@ Ask about dimensions, never from a domain template:
48
93
  mis-click in a menu. A public repo is a deliberate manual act outside this flow
49
94
  (the CLI flag exists for that; this skill never uses it).
50
95
 
96
+ **PoC:** at most 3 rounds, and none of them about features (that is the brainstorm's job
97
+ in Phase 5):
98
+
99
+ 1. What is shown, to whom, and when is the meeting. The date becomes `Demo: YYYY-MM-DD`
100
+ in `docs/MANUS.md`.
101
+ 2. Where the code lives, plus the project name (lowercase letters, digits, `. _ -`),
102
+ only when a repo must be created: a private repo in the org (default: WeAreHausTech),
103
+ a private repo on personal GitHub (omit `--org`), or local only, no GitHub repo
104
+ (`--no-github`). NEVER offer or pass `--public`.
105
+ 3. A stack hint, only if the user has one. Otherwise pick the stack yourself from the
106
+ one-line description (a Vendure storefront demo is `next` or `react-router`); a wrong
107
+ pick is cheap in a throwaway repo.
108
+
51
109
  Pick the stack yourself from the answers. Confirm the stack with the user only on
52
110
  genuine ambiguity (e.g. web vs native unclear).
53
111
 
@@ -59,6 +117,11 @@ committed to `main` in the new repo and pushed to the remote if one is created.
59
117
  ONE explicit user OK before anything touches disk — this one approval covers those
60
118
  actions.
61
119
 
120
+ **PoC:** one screen: project name, org, personal, or local only, stack and why, and the
121
+ sentence "PoC profile, private repo if one is created, thrown away after the demo on
122
+ <date>". Say that commits go to `main` until the first green manus exists. One OK covers
123
+ Phases 3 and 4.
124
+
62
125
  ## Phase 3 — Scaffold
63
126
 
64
127
  Check the registry first: `haus new --list --json`.
@@ -86,6 +149,23 @@ Check the registry first: `haus new --list --json`.
86
149
  3. Manual rails: `git init` (if the scaffolder didn't), `git branch -M main`, initial
87
150
  commit; then `gh repo create` (confirm first) unless the user declined a repo.
88
151
 
152
+ **PoC:** two ways in, decided already in Phase 0 by what the cwd was.
153
+
154
+ - **cwd is the project:** the registry is not used, because `haus new` creates
155
+ `<parent>/<name>` and refuses an existing directory. Run the official scaffolder into
156
+ `.` (show the exact command, the user confirms; e.g. `npx create-next-app@16 . --yes
157
+ --typescript --app`), then `git init` (if needed), `git branch -M main`, initial
158
+ commit. Then, unless a remote exists or local-only was chosen in Phase 1: `gh repo
159
+ create <org>/<name> --private --source . --push` (confirm first; omit `<org>/` for
160
+ personal GitHub). Local-only stops here: no `gh repo create`, no push, ever.
161
+ - **cwd is a parent folder:** the fast path with the profile: preview with
162
+ `haus new <stack> <name> --json --yes --dry-run --profile poc [--dir <path>] [--org
163
+ <org>] [--no-github]`, then run it without `--dry-run`, then `cd <name>`. Pass
164
+ `--no-github` when local-only was chosen in Phase 1; `haus new` then never runs `gh
165
+ repo create`. Carry `--dir` through from Phase 0 for a workspace member; without it a
166
+ PoC still lands in the cwd, exactly like production. The chained init records the
167
+ profile and writes the PoC standard; nothing more to do for the profile in Phase 4.
168
+
89
169
  ## Phase 4 — Context install
90
170
 
91
171
  Everything from here on runs inside the new project directory — `cd` into it first and
@@ -111,6 +191,45 @@ stay there.
111
191
  `docs/plans/walking-skeleton.md` (one task per selected feature with acceptance
112
192
  criteria and a verify command).
113
193
 
194
+ **PoC:** the profile must be on disk before the preview, because a PoC repo refuses
195
+ `haus init` without `--profile poc`, and a preview never persists the profile
196
+ (ADR-0125). Manual path, in this order:
197
+
198
+ 1. Write `.haus-workflow/haus.config.json` with exactly `{ "profile": "poc" }` (create the
199
+ directory).
200
+ 2. Read: `haus init --json --dry-run --profile poc`; on the zero-signal refusal, confirm
201
+ and re-run with `--force` as above.
202
+ 3. Write: `haus apply --write`. It reads the profile: `.haus-workflow/WORKFLOW.md` now
203
+ starts with `# PoC Workflow Standard`, and there is no `.github/workflows/haus-gate.yml`.
204
+
205
+ Fast path: the chained init already did this; check that `.haus-workflow/haus.config.json`
206
+ says `"profile": "poc"`.
207
+
208
+ Then the demo skeleton, instead of SPEC.md and the walking-skeleton plan:
209
+
210
+ - `yarn add -D @playwright/test` (or the project's package manager), then
211
+ `npx playwright install chromium` (a download: ask first).
212
+ - `playwright.config.ts` with a `webServer` that starts the dev server and takes its port
213
+ from `PORT` (default 3000), `testDir: 'demo'`, `reporter: 'line'`, `use.baseURL`
214
+ from the same port.
215
+ - `demo/manus.spec.ts` with the header comment `// The manus. One test per point in
216
+ docs/MANUS.md, same titles, same order. test.fixme() for points decided but not built.`
217
+ and no tests yet.
218
+ - `"manus": "playwright test"` in package.json scripts.
219
+ - `docs/MANUS.md`:
220
+
221
+ ```markdown
222
+ # Manus
223
+
224
+ Demo: <date from Phase 1>
225
+
226
+ ## Parked
227
+ ```
228
+
229
+ The numbered points are written by the brainstorm in Phase 5, never here.
230
+
231
+ Commit the skeleton on `main` (`chore(poc): demo skeleton`).
232
+
114
233
  ## Phase 5 — Build the walking skeleton
115
234
 
116
235
  1. Install dependencies. On the fast path the JSON's `installHint` is written for the
@@ -140,6 +259,17 @@ stay there.
140
259
  rule: it applies only to a freshly created single-author repo during this initial
141
260
  walking-skeleton build; standard branch rules apply afterwards.
142
261
 
262
+ **PoC:** now, with the PoC standard loaded, invoke superpowers:brainstorming. A new
263
+ project is architectural, so it ends in a written design: tell the skill the spec
264
+ location is `docs/MANUS.md` (numbered points in show order, each with what the customer
265
+ sees and what proves it; keep the `Demo:` header). Then superpowers:writing-plans into
266
+ `docs/plans/round-1.md`, one task per manus point with "the manus point is green" as its
267
+ verification. Build: `demo/manus.spec.ts` gets one `test()` per point as it is built and
268
+ `test.fixme()` for the rest; independent points may go to one subagent each in its own
269
+ worktree once a first green manus exists on `main`; before that, everything lands on
270
+ `main`. No `docs/DESIGN.md`, no TDD, no reviewer dispatch: the standard in the repo says
271
+ why.
272
+
143
273
  ## Phase 6 — Verify + hand off
144
274
 
145
275
  1. Gate: build passes, lint passes, tests green, dev server boots (smoke check),
@@ -159,6 +289,20 @@ stay there.
159
289
  the suggested next step — iterate per feature in fresh sessions inside the
160
290
  project directory.
161
291
 
292
+ **PoC:** the gate is the manus: `yarn manus` (or the package manager's equivalent) with
293
+ every point green or `fixme`, nothing red. Then: README with the start command, the port
294
+ and the manus command; commit `docs/MANUS.md` and `docs/plans/round-1.md`; `haus doctor`
295
+ shows `Profile: poc` and nothing needing attention; push if a remote exists (never for
296
+ local-only). Then stop: do NOT follow `references/init.md`
297
+ from step 3, because a PoC has no docs pass, no deep read and no recommend re-check. Hand off in
298
+ the user's language, naming the demo date, the two re-entry phrases and the decision the
299
+ meeting ends with: next session, open this repo and say "where are we" / "var är vi",
300
+ or "extend the demo with ..."; after the demo, decide
301
+ actively per the standard's **After the demo** section: archive the repo, or build it for
302
+ real from zero with `docs/MANUS.md` and Parked as input, never from this code. If the
303
+ fast path created `<cwd>/<name>`, say that the user opens that directory as a new Claude
304
+ Code project.
305
+
162
306
  ## Failure rules
163
307
 
164
308
  - Relay `haus` failure `detail` verbatim; never retry destructively; the project
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@haus-tech/haus-workflow",
3
- "version": "5.4.0",
3
+ "version": "5.5.0",
4
4
  "description": "Haus AI workflow CLI for Claude Code.",
5
5
  "type": "module",
6
6
  "bin": {