flow-workflows 0.114.0 → 0.115.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/README.md +10 -4
- package/adapters/codex/CORE.md +142 -134
- package/adapters/codex/skills/flow-bug-fix/SKILL.md +1 -1
- package/adapters/codex/skills/flow-bug-ship/SKILL.md +1 -1
- package/adapters/codex/skills/flow-doctor/SKILL.md +1 -1
- package/adapters/codex/skills/flow-feat-build/SKILL.md +2 -2
- package/adapters/codex/skills/flow-feat-ship/SKILL.md +1 -1
- package/adapters/codex/skills/flow-work-README/SKILL.md +5 -5
- package/adapters/codex/skills/flow-work-abandon/SKILL.md +1 -1
- package/adapters/codex/skills/flow-work-daily/SKILL.md +1 -1
- package/adapters/codex/skills/flow-work-handoff/SKILL.md +4 -3
- package/adapters/codex/skills/flow-work-resume/SKILL.md +8 -24
- package/adapters/gemini/CORE.md +142 -134
- package/adapters/gemini/commands/flow/bug/fix.toml +1 -1
- package/adapters/gemini/commands/flow/bug/ship.toml +1 -1
- package/adapters/gemini/commands/flow/doctor.toml +1 -1
- package/adapters/gemini/commands/flow/feat/build.toml +2 -2
- package/adapters/gemini/commands/flow/feat/ship.toml +1 -1
- package/adapters/gemini/commands/flow/work/README.toml +5 -5
- package/adapters/gemini/commands/flow/work/abandon.toml +1 -1
- package/adapters/gemini/commands/flow/work/daily.toml +1 -1
- package/adapters/gemini/commands/flow/work/handoff.toml +4 -3
- package/adapters/gemini/commands/flow/work/resume.toml +8 -24
- package/adapters/hermes/CORE.md +142 -134
- package/adapters/hermes/skills/flow-bug-fix/SKILL.md +1 -1
- package/adapters/hermes/skills/flow-bug-ship/SKILL.md +1 -1
- package/adapters/hermes/skills/flow-doctor/SKILL.md +1 -1
- package/adapters/hermes/skills/flow-feat-build/SKILL.md +2 -2
- package/adapters/hermes/skills/flow-feat-ship/SKILL.md +1 -1
- package/adapters/hermes/skills/flow-work-README/SKILL.md +5 -5
- package/adapters/hermes/skills/flow-work-abandon/SKILL.md +1 -1
- package/adapters/hermes/skills/flow-work-daily/SKILL.md +1 -1
- package/adapters/hermes/skills/flow-work-handoff/SKILL.md +4 -3
- package/adapters/hermes/skills/flow-work-resume/SKILL.md +8 -24
- package/adapters/opencode/CORE.md +142 -134
- package/adapters/opencode/commands/flow-bug-fix.md +1 -1
- package/adapters/opencode/commands/flow-bug-ship.md +1 -1
- package/adapters/opencode/commands/flow-doctor.md +1 -1
- package/adapters/opencode/commands/flow-feat-build.md +2 -2
- package/adapters/opencode/commands/flow-feat-ship.md +1 -1
- package/adapters/opencode/commands/flow-work-README.md +5 -5
- package/adapters/opencode/commands/flow-work-abandon.md +1 -1
- package/adapters/opencode/commands/flow-work-daily.md +1 -1
- package/adapters/opencode/commands/flow-work-handoff.md +4 -3
- package/adapters/opencode/commands/flow-work-resume.md +8 -24
- package/bin/cli.mjs +546 -12
- package/package.json +1 -1
- package/plugins/flow/.claude-plugin/plugin.json +1 -1
- package/plugins/flow/CHANGELOG.md +21 -0
- package/plugins/flow/examples/FLOW.template.md +1 -0
|
@@ -96,33 +96,17 @@ With what is new (there is already work on disk):
|
|
|
96
96
|
|
|
97
97
|
## 5. Rebuild the live panel
|
|
98
98
|
|
|
99
|
-
After a break the panel is most likely stale, and a resumed session is exactly where flow-core §4 asks for `panel_get` **before** publishing: read what is on screen, then
|
|
99
|
+
After a break the panel is most likely stale, and a resumed session is exactly where flow-core §4 asks for `panel_get` **before** publishing: read what is on screen, then render it from the state just rebuilt — `panel-input.json` written whole, then the panel CLI with `--forge` (flow-core §4), whose document goes to `panel_set` where the terminal offers the panel tools:
|
|
100
100
|
|
|
101
101
|
```json
|
|
102
|
-
{
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
"header": true,
|
|
106
|
-
"lines": [
|
|
107
|
-
{"text": "<work title>", "style": "title"},
|
|
108
|
-
"",
|
|
109
|
-
{"ref": "#1", "text": "batch read sources", "mark": "wait", "link": "https://gitlab.com/…/merge_requests/9977"},
|
|
110
|
-
{"ref": "#2", "text": "per-event counters", "mark": "current"},
|
|
111
|
-
{"ref": "#3–#6", "text": "channel map · use case · detail · route", "mark": "pending"},
|
|
112
|
-
"",
|
|
113
|
-
{"ref": "Now", "text": "nothing running — just resumed", "mark": "info"},
|
|
114
|
-
{"ref": "Next", "text": "build", "mark": "info"},
|
|
115
|
-
{"ref": "Decision", "text": "run the next step, or leave it for another work", "mark": "wait"},
|
|
116
|
-
"",
|
|
117
|
-
{"text": "sibling-repo still needs the endpoint contract", "mark": "block"}
|
|
118
|
-
]
|
|
119
|
-
}
|
|
102
|
+
{"phase": "build", "now": "nothing running — just resumed", "next": "build",
|
|
103
|
+
"decision": "run the next step, or leave it for another work",
|
|
104
|
+
"blocks": [{"text": "sibling-repo still needs the endpoint contract"}]}
|
|
120
105
|
```
|
|
121
106
|
|
|
122
107
|
- `phase` = the phase you are resuming into (`meta.json.phase` does not yet say it).
|
|
123
|
-
- `
|
|
124
|
-
- `
|
|
125
|
-
- `
|
|
126
|
-
-
|
|
127
|
-
- `updated_at` from `date -Iseconds` when the panel goes to the file; every fact from `meta.json` and the artifacts; language of the work's artifacts.
|
|
108
|
+
- `now` in prose; `next` names the phase §4 suggested.
|
|
109
|
+
- `decision` is always set after a resume — nothing is running, the next move is the user's. It goes the moment they make it (flow-core §4.4e), not at the next stop.
|
|
110
|
+
- `blocks` for the blockers §4 surfaced (`contract_handoff` `pending` in a sibling repo, a red pipeline, an unmerged dependency); `labels` in the language of the work's artifacts.
|
|
111
|
+
- The train, the steps and each MR/PR's real state come from the CLI: never typed here.
|
|
128
112
|
"""
|
package/adapters/hermes/CORE.md
CHANGED
|
@@ -17,7 +17,7 @@ Every `/flow-*` command assumes these rules. They are stated once, here, so a co
|
|
|
17
17
|
carries what is specific to its phase. Read this once per session; a command that says "load
|
|
18
18
|
`flow-core`" means this file.
|
|
19
19
|
|
|
20
|
-
**This file belongs to flow `0.
|
|
20
|
+
**This file belongs to flow `0.115.0`.** Compare it once, at the start of the session, against
|
|
21
21
|
`version` in `~/.claude/flow/.claude-plugin/plugin.json`. The two differing means the session
|
|
22
22
|
is running a **mixture** — the commands from one copy of the plugin, these shared rules from another
|
|
23
23
|
— which is exactly what happens when a branch or a release candidate is loaded over an installed
|
|
@@ -664,30 +664,76 @@ I need: <one line — the decision or action you are waiting on>
|
|
|
664
664
|
- **If it is a question, it is `AskUserQuestion`** — in `unattended`, the orchestrator's `ask` (§2.1). Never end a message with a question in prose. If it does not deserve the menu, it is a decision you take and record.
|
|
665
665
|
- **What the question is about travels with the question.** A brief, an MR/PR body, a plan, a finding: put it where the user answers it — in the question text and its options — and not only in the prose above. **Nothing runs between the two**: a tool call after that prose is what makes a terminal fold it away, and the last thing a chat UI collapses is exactly the thing they were asked to read. A gate answered without seeing what it was about is not a gate; "it is in `05-implementation.md`" is not showing it, because the answer then costs opening an editor and finding the file. Too long for the harness's question → print it as the **last** thing before asking, tool calls already done.
|
|
666
666
|
|
|
667
|
-
## 4. Live panel —
|
|
667
|
+
## 4. Live panel — rendered by `flow-workflows panel`, carried by the terminal's MCP or a file
|
|
668
668
|
|
|
669
|
-
Whenever the state a panel would show changes,
|
|
670
|
-
|
|
671
|
-
(§3).
|
|
669
|
+
Whenever the state a panel would show changes, the panel is rendered again. **Any progress line you
|
|
670
|
+
were about to type into the chat is a panel update instead** (§3).
|
|
672
671
|
|
|
673
|
-
**
|
|
674
|
-
|
|
675
|
-
|
|
676
|
-
|
|
677
|
-
`
|
|
678
|
-
|
|
679
|
-
transport, never instead of it.
|
|
672
|
+
**You do not write the panel; you write what only you know, and the CLI renders the rest.** The
|
|
673
|
+
title, the MR/PR train and each one's state, the plan's steps, sibling repos' MRs/PRs, what is still
|
|
674
|
+
open — all of it is already in `meta.json`, the plan's ticks and the forge, and a panel rebuilt from
|
|
675
|
+
prose loses it: the step block was published in 8 of 64 build sessions that had a plan, merged
|
|
676
|
+
MRs/PRs stayed `wait`, and panels from other harnesses lost their clock, their links and their
|
|
677
|
+
language. So a publication is two moves:
|
|
680
678
|
|
|
681
|
-
**
|
|
682
|
-
namespaces an MCP server's tools, so what you are looking for is a tool whose name *ends* in
|
|
683
|
-
`panel_set` — `mcp__panel__panel_set` on Claude Code, another prefix elsewhere — and the name is
|
|
684
|
-
whatever it is called there, not `panel_set`. It may also be **deferred**: listed by name with no
|
|
685
|
-
schema, uncallable until you load it, and indistinguishable from absent unless you read that list.
|
|
686
|
-
A deferred tool is a tool that is there; load the three schemas and publish. The file is the answer
|
|
687
|
-
only after that search comes back empty — and this is the one paragraph that decides it, because
|
|
688
|
-
prose describing a file is otherwise obeyed to the letter.
|
|
679
|
+
1. **Write `.claude/work/<work>/panel-input.json`** — whole, every time, only what this moment knows:
|
|
689
680
|
|
|
690
|
-
|
|
681
|
+
```json
|
|
682
|
+
{"phase": "build", "now": "unit suite over #2", "next": "review #2",
|
|
683
|
+
"decision": "confirm the MR/PR body before I create it", "attention": "wait",
|
|
684
|
+
"blocks": [{"text": "sibling-repo still needs the endpoint contract", "link": "https://…"}],
|
|
685
|
+
"stale_after_minutes": 45,
|
|
686
|
+
"labels": {"now": "Ahora", "next": "Siguiente", "decision": "Decisión", "open": "Abierto",
|
|
687
|
+
"closed": "nada más aquí", "review": "ronda de review", "findings": "abiertos",
|
|
688
|
+
"followups": "seguimientos"}}
|
|
689
|
+
```
|
|
690
|
+
|
|
691
|
+
Every field is optional. `phase` is the phase **running now**. `now` is what is running — never
|
|
692
|
+
the train restated (*"MR/PR open, waiting for review"* is what the train line already says).
|
|
693
|
+
`next` is the next phase or MR/PR — never housekeeping (*archive the work*, *remove the
|
|
694
|
+
worktree*). `decision` only while parked on the user; it sets `attention: wait` by itself.
|
|
695
|
+
`blocks` are what stops the work on somebody else — a sibling repo with `contract_handoff:
|
|
696
|
+
pending`, a red pipeline, an unmerged dependency — each with its `link` when it names an MR/PR.
|
|
697
|
+
`labels` carry the fixed words in **the language of the work's artifacts**; omitted, they are
|
|
698
|
+
English. Free text lives in this file, never on a command line.
|
|
699
|
+
2. **Run `npx flow-workflows@<version> panel --harness <harness> --forge`** from the work's
|
|
700
|
+
checkout (`<version>` this plugin's own, from `~/.claude/flow/.claude-plugin/plugin.json`
|
|
701
|
+
— the rule `/flow-feat-review` §1 gives for every `flow-workflows` call). It writes
|
|
702
|
+
`.claude/work/<work>/panel.json`, writes `card.json` beside it when `panel.artifact` is set, pipes
|
|
703
|
+
the document to `panel.publish_cmd` when that is set, and prints the document. `--forge` asks
|
|
704
|
+
`gh`/`glab` for each open MR/PR and keeps the answers in `forge-state.json`, which the renders
|
|
705
|
+
without it reuse — leave it out at a plan step (§4.4 f), where nothing in the forge moved.
|
|
706
|
+
`meta.json` is never written by it.
|
|
707
|
+
|
|
708
|
+
**Where the plugin's hooks run — Claude Code and Codex — the render also happens on its own**: a
|
|
709
|
+
`PostToolUse` hook renders the panel again whenever `meta.json`, the plan, or `panel-input.json` is
|
|
710
|
+
newer than `panel.json` and than that branch's last attempt — a render that wrote nothing is not
|
|
711
|
+
retried until one of them changes again. Ticking a step in the plan *is* publishing it there. The hook cannot reach
|
|
712
|
+
the terminal's MCP tools, which is what `panel.publish_cmd` is for (§4.2).
|
|
713
|
+
|
|
714
|
+
**The CLI unavailable** — no network for npx, a sandbox that blocks it, a non-zero exit with no
|
|
715
|
+
document — → write the §4.1 document yourself, once, by its rules, and say so at the next stop:
|
|
716
|
+
`panel: written by hand — <why>`. Never retry variants of the call.
|
|
717
|
+
|
|
718
|
+
**One panel is drawn by hand on purpose**: `/flow-work-watch` paints a monitoring cycle — verdict, latency, what it is waiting for — that no work file holds, so it writes its §5 document itself, by §4.1's rules, and the CLI is not run while it watches.
|
|
719
|
+
|
|
720
|
+
**Two transports for the one document.** When the tools `panel_set` / `panel_get` are available,
|
|
721
|
+
this console is a pane of a terminal that paints what reaches it over its MCP (§4.2). Whatever the
|
|
722
|
+
transport, `panel.json` is written — by the CLI — because the session-start hook reads its `Now` and
|
|
723
|
+
`phase` to say what the last session was doing. No work folder (lightweight `respond`/`green`) →
|
|
724
|
+
nothing to publish, either way. With `panel.artifact` set, each publication is also mirrored to a
|
|
725
|
+
claude.ai page that gathers every work of every repo (§4.6) — in addition to the transport, never
|
|
726
|
+
instead of it.
|
|
727
|
+
|
|
728
|
+
**Look for the tools before you conclude they are missing**, once per session, in pre-flight. A
|
|
729
|
+
harness namespaces an MCP server's tools, so what you are looking for is a tool whose name *ends* in
|
|
730
|
+
`panel_set` — `mcp__panel__panel_set` on Claude Code, another prefix elsewhere. It may also be
|
|
731
|
+
**deferred**: listed by name with no schema, uncallable until you load it, and indistinguishable from
|
|
732
|
+
absent unless you read that list. A deferred tool is a tool that is there; load the schemas and
|
|
733
|
+
publish. A tool that answers that this console is not one of its panes → the file is the transport
|
|
734
|
+
for the rest of the session.
|
|
735
|
+
|
|
736
|
+
### 4.1 The document — what the CLI prints, and what you write when it cannot
|
|
691
737
|
|
|
692
738
|
```json
|
|
693
739
|
{
|
|
@@ -695,105 +741,76 @@ prose describing a file is otherwise obeyed to the letter.
|
|
|
695
741
|
"phase": "validate",
|
|
696
742
|
"header": true,
|
|
697
743
|
"lines": [
|
|
698
|
-
{"text": "Expose a thread's tracking state and events", "style": "title"},
|
|
744
|
+
{"key": "title", "text": "Expose a thread's tracking state and events", "style": "title"},
|
|
745
|
+
"",
|
|
746
|
+
{"key": "mr-1", "ref": "#1", "text": "batch read sources", "mark": "wait", "link": "https://gitlab.com/…/merge_requests/9977"},
|
|
747
|
+
{"key": "mr-1-state", "text": "pipeline passed · 0/1 approvals · 2 open threads", "mark": "info", "indent": 4},
|
|
748
|
+
{"key": "mr-2", "ref": "#2", "text": "per-event and per-recipient counters", "mark": "current"},
|
|
749
|
+
{"key": "step-1", "ref": "1", "text": "counter columns + migration", "mark": "done", "indent": 4},
|
|
750
|
+
{"key": "step-2", "ref": "2", "text": "per-recipient aggregation in the use case", "mark": "current", "indent": 4},
|
|
751
|
+
{"key": "step-3", "ref": "3", "text": "expose both counters on the endpoint", "mark": "pending", "indent": 4},
|
|
752
|
+
{"key": "mr-3-6", "ref": "#3–#6", "text": "channel map · use case · document detail · route", "mark": "pending"},
|
|
753
|
+
"",
|
|
754
|
+
{"key": "sib-1", "ref": "mcp !71", "text": "pipeline running", "mark": "wait", "link": "https://gitlab.com/…/mcp/-/merge_requests/71"},
|
|
699
755
|
"",
|
|
700
|
-
{"
|
|
701
|
-
{"ref": "#2", "text": "per-event and per-recipient counters", "mark": "current"},
|
|
702
|
-
{"ref": "1–2", "text": "counter columns + migration · repository query", "mark": "done", "indent": 4},
|
|
703
|
-
{"ref": "3", "text": "per-recipient aggregation in the use case", "mark": "current", "indent": 4},
|
|
704
|
-
{"ref": "4", "text": "expose both counters on the endpoint", "mark": "pending", "indent": 4},
|
|
705
|
-
{"ref": "#3–#6", "text": "channel map · use case · document detail · route", "mark": "pending"},
|
|
756
|
+
{"key": "open", "ref": "Open", "text": "review round 2 · 1 open · 2 follow-ups", "mark": "info"},
|
|
706
757
|
"",
|
|
707
|
-
{"ref": "Now", "text": "unit suite and the test agent over #2", "mark": "info"},
|
|
708
|
-
{"ref": "Next", "text": "ship #2", "mark": "info"},
|
|
709
|
-
{"ref": "Decision", "text": "confirm the MR/PR body before I create it", "mark": "wait"},
|
|
758
|
+
{"key": "now", "ref": "Now", "text": "unit suite and the test agent over #2", "mark": "info"},
|
|
759
|
+
{"key": "next", "ref": "Next", "text": "ship #2", "mark": "info"},
|
|
760
|
+
{"key": "decision", "ref": "Decision", "text": "confirm the MR/PR body before I create it", "mark": "wait"},
|
|
710
761
|
"",
|
|
711
|
-
{"text": "sibling-repo still needs the endpoint contract", "mark": "block"}
|
|
762
|
+
{"key": "block-1", "text": "sibling-repo still needs the endpoint contract", "mark": "block"}
|
|
712
763
|
]
|
|
713
764
|
}
|
|
714
765
|
```
|
|
715
766
|
|
|
716
|
-
- **`mark` says what a line is**; the reader draws it. `done` · `current` (at most one per block) · `pending` · `wait` (waiting on someone else: an open MR/PR, a user decision) · `block` · `info`.
|
|
717
|
-
- **`
|
|
718
|
-
-
|
|
719
|
-
- **
|
|
720
|
-
|
|
721
|
-
|
|
722
|
-
|
|
723
|
-
|
|
724
|
-
|
|
725
|
-
|
|
726
|
-
|
|
727
|
-
|
|
728
|
-
|
|
729
|
-
|
|
730
|
-
|
|
731
|
-
|
|
732
|
-
|
|
733
|
-
|
|
734
|
-
- **
|
|
735
|
-
|
|
736
|
-
|
|
737
|
-
|
|
738
|
-
**
|
|
739
|
-
|
|
740
|
-
|
|
741
|
-
|
|
742
|
-
|
|
743
|
-
|
|
744
|
-
|
|
745
|
-
|
|
746
|
-
|
|
747
|
-
|
|
748
|
-
|
|
749
|
-
|
|
750
|
-
|
|
751
|
-
first: the worst case is that nothing happened and you were told why.
|
|
752
|
-
- **A patch whose answer never arrived may have been applied — send it again.** The resend is
|
|
753
|
-
refused rather than doubling the line.
|
|
754
|
-
- At most 64 ops per call. `actions` are not patchable: change buttons with a whole `panel_set`.
|
|
755
|
-
- Republish with `panel_set` only when the *shape* changes (a new MR/PR train, a different body).
|
|
756
|
-
|
|
757
|
-
**Refusals are information, not noise.** `no line of this panel carries the key "…"` → your keys and
|
|
758
|
-
the panel disagree: `panel_get` and republish. `publish with panel_set before patching` → this pane
|
|
759
|
-
is still on its file. `this panel is held by "…"` → another producer owns it; do not fight it, say
|
|
760
|
-
so at the next stop.
|
|
761
|
-
|
|
762
|
-
**After a compaction, a restart or a resumed work**, call `panel_get` **before publishing**. It
|
|
763
|
-
returns the document on screen — yours or one that arrived by file — and publishing it back leaves
|
|
764
|
-
the panel exactly as it is. What comes back is the document as the app understood it: unknown fields
|
|
765
|
-
are gone and defaults come back absent.
|
|
766
|
-
|
|
767
|
-
**Optional — buttons at a stop.** At a stop parked on the user, `actions` (up to 8) paint a button
|
|
768
|
-
whose command is shown literally and is written into this pane's program on one click — which here
|
|
769
|
-
is this very session's prompt. So `{"label": "Approve the design", "send": "approve"}` answers you
|
|
770
|
-
without the user typing. Plain text, no line breaks, never a credential: it is painted on screen and
|
|
771
|
-
lands in the shell history.
|
|
772
|
-
|
|
773
|
-
### 4.3 Without those tools — `.claude/work/<work>/panel.json`
|
|
774
|
-
|
|
775
|
-
Overwrite the file **whole** (never patch) with the §4.1 document. `updated_at` from the real clock
|
|
776
|
-
(`date -Iseconds`), never carried over — it is how the reader flags a stale snapshot. `attention`
|
|
777
|
-
and `key` buy nothing here: the file panel is drawn from `mark` and `ref` alone.
|
|
767
|
+
- **`mark` says what a line is**; the reader draws it. `done` · `current` (at most one per block) · `pending` · `wait` (waiting on someone else: an open MR/PR, a user decision) · `block` · `info`. Do not set `style` on a marked line — except `mark: "info"` + `style: ok|warn|error` when the colour *is* the information (a monitoring verdict, the closing line).
|
|
768
|
+
- **`link` is a field, never a URL inside `text`**, and every line that names an MR/PR carries it.
|
|
769
|
+
- **Order:** the title (`meta.json.title` without the ticket id: `header: true` draws ticket, type, phase and age); the MR/PR train, one entry per `meta.json.mrs[]` (a single MR/PR from `mr_url`), not-started ones folded into one `#a–#z` line, each open one followed by its state from the forge; under the MR/PR being built — or the bug in `fix` — its plan's steps from the ticks, never ahead of them, at most five lines (past three done they fold, a long pending tail folds); sibling repos' MRs/PRs; one `Open` line for the latest review round's open findings and the open follow-ups; `Now`, `Next`, `Decision`; blockers. A finished work (`meta.json.phase` `done`) shows its train, one `info`/`ok` closing line and `attention: done`, and nothing else.
|
|
770
|
+
- **Rules:** every fact from `meta.json`, the artifacts and the forge — an invented MR/PR state is worse than a blank panel. Keep it under ~14 lines.
|
|
771
|
+
|
|
772
|
+
### 4.2 Over the terminal's MCP — `panel_set` with what the CLI printed
|
|
773
|
+
|
|
774
|
+
**Every publication is one `panel_set`** — `source: "flow"`, `document` the JSON the CLI just
|
|
775
|
+
printed, which already carries a `key` on every line and the top-level `attention`: `wait` when
|
|
776
|
+
parked on the user, `block` when stuck on somebody else, `done` when the work closed, absent while
|
|
777
|
+
simply working. The terminal never deduces it from the body, and a `wait` left behind flags that tab
|
|
778
|
+
for ever — so the next render, which drops the `decision`, is what clears it. The first `panel_set`
|
|
779
|
+
claims the pane for as long as this session lives; a second producer is refused by name.
|
|
780
|
+
|
|
781
|
+
- `panel_patch` is for the CLI-unavailable case only (§4): there, patch by `key` rather than
|
|
782
|
+
rebuild — ops `replace`, `before`, `after`, `delete`, `first`, `last`, `set` (`phase`,
|
|
783
|
+
`attention`, `header`, `stale_after_minutes`); the whole list applies or none of it does, and a
|
|
784
|
+
resend of a patch whose answer never arrived is refused rather than doubling a line.
|
|
785
|
+
- **Refusals are information.** `this panel is held by "…"` → another producer owns it; do not fight
|
|
786
|
+
it, say so at the next stop.
|
|
787
|
+
- **After a compaction, a restart or a resumed work**, call `panel_get` before publishing: it returns
|
|
788
|
+
what is on screen, which may have arrived from elsewhere.
|
|
789
|
+
- **A hook cannot call these tools.** Where the reader is a terminal like this one, the person sets
|
|
790
|
+
`panel.publish_cmd`, in a git-ignored FLOW file, to whatever command that terminal offers for
|
|
791
|
+
publishing a document from a shell; the CLI pipes every render into it, the hook's included.
|
|
792
|
+
- **Optional — buttons at a stop.** At a stop parked on the user, `actions` (up to 8) paint a button
|
|
793
|
+
whose command is written into this pane's program on one click — this very session's prompt. Add
|
|
794
|
+
them to the printed document before `panel_set`: `{"label": "Approve the design", "send":
|
|
795
|
+
"approve"}`. Plain text, no line breaks, never a credential.
|
|
796
|
+
|
|
797
|
+
### 4.3 Without those tools — the file is the transport
|
|
798
|
+
|
|
799
|
+
`panel.json` is what the CLI already wrote: nothing else to do. Written by hand (the CLI
|
|
800
|
+
unavailable), overwrite the file **whole** with the §4.1 document and `updated_at` from the real
|
|
801
|
+
clock (`date -Iseconds`), never carried over — it is how a reader flags a stale snapshot.
|
|
778
802
|
|
|
779
803
|
### 4.4 When to publish — whichever transport is in play
|
|
780
804
|
|
|
781
805
|
(a) In pre-flight, as soon as `meta.json` is loaded; (b) immediately **before** every stop header;
|
|
782
806
|
(c) **before** any long stretch (fan-out, full suite, CI poll) — never after, so a step that dies
|
|
783
807
|
halfway is not shown as finished. When the stretch will outlast the ~30 min staleness warning, set
|
|
784
|
-
`stale_after_minutes` to what it will really take; (d) wherever `## Close` updates
|
|
785
|
-
|
|
786
|
-
|
|
787
|
-
|
|
788
|
-
the
|
|
789
|
-
|
|
790
|
-
that never asked, because they answered it and the screen says it did not land; and an `attention`
|
|
791
|
-
nobody clears keeps that tab claiming them for ever. The same applies to a blocker that lifted and
|
|
792
|
-
to a `wait` line whose MR/PR merged.
|
|
793
|
-
|
|
794
|
-
**(f) Each plan step that lands** (the (2b) block): one patch, the moment its tick goes into the
|
|
795
|
-
phase artifact — that step to `done`, the next to `current`, `Now` moved on. Not batched at the end
|
|
796
|
-
of the MR/PR: a list that jumps from nothing to finished told the user nothing while it mattered.
|
|
808
|
+
`stale_after_minutes` in the input to what it will really take; (d) wherever `## Close` updates
|
|
809
|
+
`meta.json`; (e) **the moment a question is answered or a gate is cleared** — before you resume the
|
|
810
|
+
work: drop `decision` from the input, move `now` on, render. A panel still asking what the user
|
|
811
|
+
already answered is worse than one that never asked; (f) **each plan step that lands** — tick it in
|
|
812
|
+
the phase artifact, move `now` on, render without `--forge`. Where the plugin's hook runs, the tick
|
|
813
|
+
and the input change already rendered it; publish over the tools anyway when they are there.
|
|
797
814
|
|
|
798
815
|
### 4.5 `meta.json.cost[]` — what a phase measured, when it could
|
|
799
816
|
|
|
@@ -834,26 +851,17 @@ section does not exist: no artifact tool is loaded or called.
|
|
|
834
851
|
(f), a plan step, only when the card's last write is 10 minutes old or more: every write is a
|
|
835
852
|
tool call, and outside auto mode a prompt, while a card left alone for 30 minutes reads as a dead
|
|
836
853
|
session on the page.
|
|
837
|
-
- **What**:
|
|
838
|
-
|
|
839
|
-
|
|
840
|
-
|
|
841
|
-
|
|
842
|
-
|
|
843
|
-
|
|
844
|
-
|
|
845
|
-
|
|
846
|
-
panel clears `attention` and carries a `block` line; the card says `done`). An open MR/PR
|
|
847
|
-
waiting to merge is not over. The page reads the state from this field alone.
|
|
848
|
-
- `repo` (the repo id below), `work` (the work folder's name), `ticket`, `type`, `branch`, and
|
|
849
|
-
`harness` (`Claude Code`), from `meta.json` and git.
|
|
854
|
+
- **What**: `card.json`, which the CLI writes beside `panel.json` whenever `panel.artifact` is set
|
|
855
|
+
— the rendered document plus `repo`, `work`, `ticket`, `type`, `branch` and `harness` — passed as
|
|
856
|
+
`file_path` to the `set`. Never a document rebuilt in your head. Its `attention` is the
|
|
857
|
+
document's: `done` once `meta.json.phase` is `done`, or once every MR/PR of the work and every MR/PR
|
|
858
|
+
recorded for its sibling repos has merged (the forge's word counts) with no Decision or blocker left in the
|
|
859
|
+
session's own input; an abandoned work claims nobody (its input carries only the `block` line
|
|
860
|
+
saying why); an open MR/PR waiting to merge is not over. The page reads
|
|
861
|
+
the state from that field alone. The CLI unavailable → the hand-written §4.1 document with those
|
|
862
|
+
six fields added.
|
|
850
863
|
- **Where**: action `set` — the whole document, so a line dropped from the panel leaves the card —
|
|
851
|
-
`url` the key's value, collection `works`, doc id `<repo
|
|
852
|
-
path of `git remote get-url origin` — everything after the host, which ends at the first `/` after
|
|
853
|
-
`//` (`https://host/owner/repo.git`, `ssh://git@host:22/owner/repo.git`) or at the first `:`
|
|
854
|
-
(`git@host:owner/repo.git`) — with `.git` dropped and every `/` turned into `.`: `owner.repo`,
|
|
855
|
-
`group.subgroup.repo`. No remote → the main checkout's directory name (§0). Any character outside
|
|
856
|
-
`[A-Za-z0-9_.~:@+-]` becomes `-`.
|
|
864
|
+
`url` the key's value, collection `works`, doc id `<repo>--<work>`, both read from `card.json`.
|
|
857
865
|
- **Version**: a write to a card that exists needs `if_version`, the version the last write
|
|
858
866
|
returned. Keep it in the session — one writer per card, so it is right until the session loses
|
|
859
867
|
it. None held → one `get` first: the card exists → pin to its version; it does not → write
|
|
@@ -866,14 +874,14 @@ section does not exist: no artifact tool is loaded or called.
|
|
|
866
874
|
mirror off or the key empty → nothing to do. A folder moved back out of `_archive/` gets its card
|
|
867
875
|
again at its next publication.
|
|
868
876
|
- **A card whose MR/PR moved without its session.** A merge or a close done in the forge has no
|
|
869
|
-
session to write it, and the card keeps asking. `/flow-work-daily` and `/flow-work-clean`
|
|
870
|
-
|
|
871
|
-
|
|
872
|
-
|
|
873
|
-
`
|
|
874
|
-
|
|
875
|
-
|
|
876
|
-
next phase, or `clean`, closes it.
|
|
877
|
+
session to write it, and the card keeps asking. `/flow-work-daily` and `/flow-work-clean` read
|
|
878
|
+
`works` once (`list`) when the mirror is on, and for each card of this repo whose train still
|
|
879
|
+
shows an MR/PR open, run `panel --harness <harness> --work <work> --forge` and `set` the
|
|
880
|
+
`card.json` it wrote — the forge's answer turns that line `done` or `block`, and the card closes
|
|
881
|
+
(`attention: done`, no Decision) once every MR/PR of the work, siblings included, has merged:
|
|
882
|
+
rendered for another branch, the input is that session's last word, not a live question. Such a
|
|
883
|
+
render writes only the card: that work's `panel.json` is its own session's pane. Same version pinning as above; `meta.json` is not
|
|
884
|
+
touched — the work's own next phase, or `clean`, closes it.
|
|
877
885
|
- **Failure never stops a phase.** A second version refusal → no more retries for that
|
|
878
886
|
publication. Any other failure — a wrong URL, auth, a permission prompt the user declined — turns
|
|
879
887
|
the mirror off for the rest of the session. Either way the next stop carries one line,
|
|
@@ -125,7 +125,7 @@ Save it in `04-fix.md` under `## Plan`, right after the brief. **A fix that was
|
|
|
125
125
|
|
|
126
126
|
- Apply the minimal fix targeting the finding of `03-investigation.md` (or the diagnosis if investigate was skipped).
|
|
127
127
|
- Sensitive area (authentication, payments, sensitive data) → consult the `agents.architecture` agent from FLOW.md to confirm the correct layer; empty → check against `conventions` in FLOW.md.
|
|
128
|
-
- More than 2 fix steps → the §2.0bis plan is already written: tick its numbered steps off in `04-fix.md` where they stand, and
|
|
128
|
+
- More than 2 fix steps → the §2.0bis plan is already written: tick its numbered steps off in `04-fix.md` where they stand, and render the panel as each lands — the panel CLI draws the steps from those ticks (flow-core §4.1, §4.4 (f)); a harness task list, if there is one, goes on top as `/flow-feat-build §2.1` says. One task per step, same order, marked `in_progress` and `completed` as they go — not batched.
|
|
129
129
|
- **Comment discipline**: comment only a *why* the code cannot say (a non-obvious constraint, the reason for a workaround, a subtle invariant); match the surrounding file's comment density. **Never write the ticket ID or "fix for #N" into a code comment** — that lives in the commit/branch/MR-PR.
|
|
130
130
|
- Keep the log updated while editing.
|
|
131
131
|
|
|
@@ -201,7 +201,7 @@ posted as comments anchored on the changed lines of the MR/PR, confirmed in ever
|
|
|
201
201
|
- **A worktree does not own the tree its tools wrote into — `/flow-feat-ship` §5.5, in full and unchanged.** First, before anything below: `meta.json.worktree` not null → read the main checkout's `git status --porcelain`, name any paths it holds in one line as what they are (in the main checkout, not in the branch just pushed, and not necessarily put there by this run), and offer once to carry them over. The knowledge files are no longer the expected case — flow-core §0 step 4 moved them into the worktree before the commit, whether `postmortem` or §3.1 saved them — so what is left here is another tool's output, or a move that went wrong.
|
|
202
202
|
- **Knowledge still owed — `/flow-feat-ship` §5, in full and unchanged**: `meta.json.knowledge.status` `later` or `failed` → offered once on this re-run; onto the open branch, or a knowledge-only MR/PR once the fix merged.
|
|
203
203
|
- Update `meta.json`: add `ship` to `phases_done`, update `updated_at`. **`phase` becomes `done` only once the MR/PR is confirmed merged** — creating it is not finishing it. Right after §3.1 it is open, so ask once with `AskUserQuestion` whether it has already been merged: **no** (the normal answer) → leave `phase = "ship"`; **yes** → `phase = "done"`. `/flow-work-green` and `/flow-work-respond` work on the open MR/PR; `/flow-work-clean` only sweeps what merged.
|
|
204
|
-
-
|
|
204
|
+
- Render the panel (flow-core §4, with `--forge`): while the MR/PR is open its line is `wait` with its real state; once merged it is `done`, and at `phase = "done"` the CLI closes the panel itself. Drop `decision` from the input either way.
|
|
205
205
|
- Overwrite `00-summary.md` whole (≤15 lines, flow-core §5).
|
|
206
206
|
- **Tracker: move to done.** **Only when this ship set `phase = "done"`** (merge confirmed just above) and `tracker.tool` is not `none`/empty, `tracker.done_cmd` is set, and `meta.json.ticket` is a **real tracker id**: run `tracker.done_cmd` with `{TICKET}` = `meta.json.ticket`. Never on an open MR/PR. If the answer was "not merged", skip silently — the transition belongs to whoever confirms the merge (`/flow-work-clean` reports the branch as merged, and re-running this close is legitimate). Same contract as `/flow-bug-start §4.5`: **best-effort, idempotent, gated** (ask once in `autonomy.mode: manual`; automatic in `guided`/`auto`); failure or already-done ticket → warn and continue, never block. **Leave `tracker.done_cmd` empty on GitHub/GitLab** — `Closes #N` already auto-closes on merge; this is for Jira/Linear-style trackers.
|
|
207
207
|
- Summarize: ticket, MR/PR URL, regression test added.
|
|
@@ -225,7 +225,7 @@ refuse) · **degraded** (it runs, quietly worse than the config promises), plus
|
|
|
225
225
|
`.agents/agents`, or a plugin. Report each missing name and that it falls back per flow-core §6.6 — the installed agent
|
|
226
226
|
that fits, else `general-purpose` (a skill: skipped) — a panel missing agents reviews less and still reports a clean pass.
|
|
227
227
|
- Harness cannot set a model per subagent → note that every `models.*` value degrades to inheritance.
|
|
228
|
-
- **Where the live panel will go this session** (flow-core §4): a tool whose name ends in `panel_set` / `panel_patch` — namespaced by the harness (`mcp__panel__panel_set` on Claude Code) and possibly **deferred**, which reads as absent until the list of deferred tools is checked → the terminal draws the panel
|
|
228
|
+
- **Where the live panel will go this session** (flow-core §4): a tool whose name ends in `panel_set` / `panel_patch` — namespaced by the harness (`mcp__panel__panel_set` on Claude Code) and possibly **deferred**, which reads as absent until the list of deferred tools is checked → the terminal draws the panel; genuinely absent → `panel.json` is the transport. Either way the panel CLI writes `panel.json`; with `panel.publish_cmd` set, one line with its value and the file it came from — a fault when that file is tracked by git, where the CLI refuses to run it. Neither is a fault — one line naming the tools as they are actually called here, or saying the file is the transport.
|
|
229
229
|
- **The artifact mirror** (flow-core §4.6) — `panel.artifact` empty and the artifact tools here → one information line, not a fault: *control room off — `/flow-init room` turns it on*. Set: one line with its value and the file it came from; whether a tool whose name ends in `ArtifactData` is here (deferred counts); and, when it is, whether a `list` of collection `works` (limit 1) on that URL answers — a read, never a write. Tool present → also name the rule that keeps every card update from asking — `ArtifactData` (as the harness calls it) under `permissions.allow` — and its cost in the same line: it lets any session write to the data of any of your artifacts without asking, not only this page's; without it, each card update is approved by hand. The value coming from any file but `FLOW.claude.md` → a fault: the URL is one person's page, and a committed `FLOW.md` hands it to every teammate, whose writes it refuses. Key set and no tool → *off in this harness*, not a fault. The read failing → the error, as a fault. The read answering → also the page's version (`flow-room-page`, through an Artifact `read`) against the plugin's example: older or absent → one information line, *control room page out of date — the next card write republishes it*, not a fault.
|
|
230
230
|
|
|
231
231
|
### 2.3 Knowledge sources
|
|
@@ -188,7 +188,7 @@ Execution mode:
|
|
|
188
188
|
|
|
189
189
|
Use `TaskCreate` to track the steps of the **§2.0ter plan for this MR/PR** — one task per numbered step, same order. Step skipped there (small MR/PR) → seed from `03-design.md` §"Implementation plan (order)", taking only the steps this MR/PR covers per `04-mr-plan.md`; the feature's plan predates the split and carries steps that belong to siblings. Mark each step `in_progress` when starting and `completed` when done — do not batch.
|
|
190
190
|
|
|
191
|
-
**The steps go to the live panel** (flow-core §4.1
|
|
191
|
+
**The steps go to the live panel** (flow-core §4.1, §4.4 (f)) — that is the list the user watches, whatever the harness. The panel CLI draws them from the ticks in `05-implementation.md`: render the panel when the first step starts and again as each one lands — where the plugin's hook runs, the tick itself renders it.
|
|
192
192
|
|
|
193
193
|
**A harness task list is optional on top.** `TaskCreate` is the Claude Code name; a harness may call it otherwise (`TodoWrite` on older builds), list it **deferred** — by name only, uncallable until its schema is loaded — or not offer it at all (Claude Code withholds it from newer models unless `CLAUDE_CODE_ENABLE_TODO_TOOLS=true`). There → seed it too; not there → nothing is missing and nothing is said. Either way the plan in `05-implementation.md` is the record: tick each step there (`- [x]`) as it lands — the panel and any task list follow the ticks, never the other way round.
|
|
194
194
|
|
|
@@ -241,7 +241,7 @@ The step's changes are **always reported before anything is recorded**. Who deci
|
|
|
241
241
|
|
|
242
242
|
**After completing each plan step**:
|
|
243
243
|
|
|
244
|
-
1. **Tick the step** in `05-implementation.md`,
|
|
244
|
+
1. **Tick the step** in `05-implementation.md`, move `now` on in `panel-input.json` and render the panel (flow-core §4.4 (f)), and mark it `completed` in the harness task list if there is one (§2.1).
|
|
245
245
|
2. **Report to the user** a step summary (≤ 5 lines):
|
|
246
246
|
```
|
|
247
247
|
Step N done: <description>
|
|
@@ -436,7 +436,7 @@ In every scenario:
|
|
|
436
436
|
```
|
|
437
437
|
|
|
438
438
|
Nothing back → the content is **not** on the base whatever the forge says (see §6.2.1). Do not mark the entry `merged`: leave it `in_progress` with a `note`, tell the user in one line, and recover it with a fresh MR/PR against `git.default_base` before the train moves on.
|
|
439
|
-
-
|
|
439
|
+
- Render the panel from the updated `meta.json` (flow-core §4, with `--forge`): a shipped-but-open MR/PR draws as `wait` with its real state, `done` once merged; when this ship sets `phase = "done"` the CLI closes the panel itself (nothing left here, `attention: done`) — drop `decision` from the input.
|
|
440
440
|
- Overwrite `00-summary.md` whole (≤15 lines, flow-core §5).
|
|
441
441
|
|
|
442
442
|
### 6.1.1 Tracker: move to done
|
|
@@ -42,7 +42,7 @@ This system **orchestrates** the project's existing sub-agents and skills (it do
|
|
|
42
42
|
- **Shared rules live in the `flow-core` skill** (`skills/flow-core/SKILL.md`): configuration merge,
|
|
43
43
|
`models`, autonomy and hard gates, never-a-question list, stop header, the live panel,
|
|
44
44
|
`00-summary.md`. Every command loads it once per session.
|
|
45
|
-
- **One folder per ticket**: `.claude/work/{TICKET}/` holds `meta.json`, `00-summary.md`, the numbered markdown artifacts
|
|
45
|
+
- **One folder per ticket**: `.claude/work/{TICKET}/` holds `meta.json`, `00-summary.md`, the numbered markdown artifacts, `panel-input.json` (what the agent knows right now) and `panel.json` (the panel the CLI rendered from all of them).
|
|
46
46
|
- **Numbered artifacts**: each phase writes a `NN-phase.md` that the next step reads.
|
|
47
47
|
- **`evidence/`**: what `/flow-*-validate` actually observed when it drove the running app — a screenshot, a response body, a log excerpt, one file per criterion, with a **before** where the change alters something already visible. `/flow-*-ship` attaches it to the MR/PR description. `quality.evidence: off` disables both halves.
|
|
48
48
|
- **`meta.json` is the source of truth** for state (current phase, size, branch). Without it, commands refuse to continue.
|
|
@@ -67,7 +67,7 @@ This system **orchestrates** the project's existing sub-agents and skills (it do
|
|
|
67
67
|
- **Commits follow the autonomy mode** (`/flow-feat-build` §2.2, `/flow-bug-fix` §2.1): changes **always reported before anything is recorded**. `manual`: **no `git commit` on its own**. `guided`: asks **once**. `auto`: WIP commit per step, cut by step (§2.3) — **`autonomy.mode: auto` plus typing the command is the explicit authorization**. WIP commits on the work branch **only**; push and MR/PR creation stay hard gates in every mode.
|
|
68
68
|
- **A named next command is not a handoff**: each `## Close` carries the **autonomy handoff** — `manual` proposes the next command with one `AskUserQuestion`; `guided`/`auto` **chain in the same turn**. Never chained: `ship` (hard gate in every mode) and anything downstream of a red gate.
|
|
69
69
|
- **Every stop opens with where you are** (flow-core §3): stop header, then ≤ ~10 product-altitude lines. Own process → the artifact; subagent notifications never earn a turn.
|
|
70
|
-
- **The stop is also published to the live panel** ([document below](#the-panel-document), flow-core §4):
|
|
70
|
+
- **The stop is also published to the live panel** ([document below](#the-panel-document), flow-core §4): rendered by `flow-workflows panel` from `meta.json`, the plan's ticks, the forge and `panel-input.json`, then carried by the terminal's `panel_set` where it exists — `panel.json` is written either way, and the plugin's hook re-renders it when those files change (Claude Code, Codex). Published **before** a long stretch, never after.
|
|
71
71
|
- **What is never a question is as binding as what always is**: hard gates stop in **every** mode; in `guided`/`auto` flow mechanics, WIP commits, the train's next MR/PR, size confirmation and anything already decided are never asked (flow-core §2). Only new evidence reopens a decision.
|
|
72
72
|
- **A correction is a convention, and a convention is written down**: when the user overrides something a phase proposed and the same correction would apply to an unrelated ticket in this repo, it becomes a `meta.json.conventions_candidates[]` row and a `## Conventions learned` line in the phase artifact, asking nothing (flow-core §8). `review`'s idiom audit reads them in the same work; `ship` offers them to `FLOW.md` once, at Close, in every mode. What is about *this* ticket stays in the artifact and goes no further.
|
|
73
73
|
- **Work you decide not to do is recorded, not narrated**: every "idea for a separate ticket", out-of-scope piece, unmitigated risk, unchecked edge case and prevention action becomes a `meta.json.followups[]` entry (flow-core §7) alongside its artifact section. Written without asking, and only when it clears the bar of §7 (a named subject, a path someone has actually seen, waiting costing more than doing it). Triaged **once** at `ship`'s Close, behind a skeptic: 3 or more candidates go to an agent whose job is to refute that each deserves a ticket, and only the strongest `tracker.followup_ask_max` (empty → **2**) become questions (**Do it** / **Not worth it** / **Later**). The rest are logged. Published in the MR/PR description while still open, and surfaced by `status`/`daily`/`next` — from `_archive/` too — until decided. Creating the tracker issue for an accepted one is outward-facing: **asks in every mode**. Two kinds are not deferred work: a **`decision`** the diff depends on is asked when it surfaces (in every mode) and only a deferred one is recorded; a **`tooling`** gap is recorded with no question at all and never goes to the tracker.
|
|
@@ -183,7 +183,7 @@ This system **orchestrates** the project's existing sub-agents and skills (it do
|
|
|
183
183
|
|
|
184
184
|
## The panel document
|
|
185
185
|
|
|
186
|
-
`meta.json` is the *state machine*; the panel is the *view* a reader outside the chat watches. Optional: a work that never publishes it still resolves from `meta.json` alone.
|
|
186
|
+
`meta.json` is the *state machine*; the panel is the *view* a reader outside the chat watches. Optional: a work that never publishes it still resolves from `meta.json` alone. `flow-workflows panel` renders it (flow-core §4): order, ceiling and the derived lines are the CLI's; what the agent supplies is `panel-input.json`. The document below is what it prints, and what a phase writes by hand only when the CLI is unavailable.
|
|
187
187
|
|
|
188
188
|
```json
|
|
189
189
|
{
|
|
@@ -216,11 +216,11 @@ This system **orchestrates** the project's existing sub-agents and skills (it do
|
|
|
216
216
|
- **`phase`** — the phase running **right now** (`meta.json.phase` advances only at close); the reader prefers it.
|
|
217
217
|
- **`updated_at`** — local ISO-8601 with offset from the real clock, never carried over; lets the reader flag a stale snapshot. Over the tools the app stamps each delivery itself.
|
|
218
218
|
- **`attention`** *(tools only)* — `wait` · `block` · `done`, beside `phase`, absent while simply working: the pane's claim on the user's attention, which the app never deduces from a line's `mark`. A tab's card shows the strongest claim among its panes, so an uncleared `wait` flags that tab for ever — it goes, with the `Decision` line, the moment the question is answered (flow-core §4.4e).
|
|
219
|
-
- **`key`**
|
|
219
|
+
- **`key`** — a unique, never-painted name on every line the CLI renders (`title`, `mr-1`, `mr-1-state`, `step-3`, `sib-1`, `open`, `now`, `next`, `decision`, `block-1`, `closed`).
|
|
220
220
|
|
|
221
221
|
**No headings over the train.** A shipped MR/PR is *open, waiting to merge*; `mark` says it per entry — `wait` shipped, `current` being worked, `done` only merged.
|
|
222
222
|
|
|
223
|
-
**The artifact mirror** (opt-in, flow-core §4.6). With `panel.artifact` set — in `FLOW.claude.md`, Claude Code only — each publication is also written (a per-step
|
|
223
|
+
**The artifact mirror** (opt-in, flow-core §4.6). With `panel.artifact` set — in `FLOW.claude.md`, Claude Code only — each publication is also written (a per-step render only when the card is 10 minutes old), whole, as one card of a claude.ai page that gathers every work of every repo: the `card.json` the CLI writes beside `panel.json` — the document plus `repo`, `work`, `ticket`, `type`, `branch`, `harness` — set as doc `<repo>--<work>` in collection `works`. The page is `examples/panel-artifact.html`, which `/flow-init room` publishes. The transport above is unchanged.
|
|
224
224
|
|
|
225
225
|
**Who publishes it.** The 18 phase commands (flow-core §4); `/flow-feat-ship` and `/flow-bug-ship` the instant an MR/PR URL exists; `/flow-feat-plan` when the train is populated — a new train is a new shape, so a full republish; `/flow-work-resume` (§5), after reading what is on screen; `/flow-work-watch` every cycle; `/flow-work-abandon` with a terminal state. Read-only `status`, `daily`, `config`, `doctor`, `news` never publish; `/flow-work-clean` archives the folder with any panel file inside.
|
|
226
226
|
|
|
@@ -93,7 +93,7 @@ Ask the user what to do with the branch — do not decide alone:
|
|
|
93
93
|
- Update `meta.json`: `phase = "abandoned"`; `phases_done` not touched (it reflects what was actually done); `notes` += abandonment reason; `updated_at` updated.
|
|
94
94
|
- Overwrite `00-summary.md` whole (≤15 lines, flow-core §5).
|
|
95
95
|
- **Tracker: move to won't-do** (never "done" — this work did not ship). Only if `tracker.tool` is not `none`/empty, `tracker.abandon_cmd` is set, and `meta.json.ticket` is a **real tracker id** (skip for local-only slugs). Run `tracker.abandon_cmd` substituting `{TICKET}` = `meta.json.ticket`. Same contract as `/flow-feat-start §6.5`: **best-effort, idempotent, gated** (ask once in `autonomy.mode: manual`; automatic in `guided`/`auto`); failure or already-in-state ticket → warn and continue, never block. `tracker.abandon_cmd` empty → do nothing (the user closes the ticket by hand if they want).
|
|
96
|
-
- Panel published for this work (flow-core §4) →
|
|
96
|
+
- Panel published for this work (flow-core §4) → render a terminal state before archiving: `panel-input.json` holding only one `blocks` entry saying the work was abandoned and why, after `meta.json.phase` is `abandoned` — the CLI then draws no Now, Next or Decision and claims nobody's attention.
|
|
97
97
|
- Delete the work's card from the artifact control room when `panel.artifact` is set (flow-core §4.6, *a card ends with its work folder*), then move the folder to `.claude/work/_archive/` **keeping its directory name** (`_archive/<work-dir>/`, the folder located in §1 — e.g. `<TICKET>-<slug>`) so `/flow-work-daily` no longer lists it.
|
|
98
98
|
- Report to the user: ticket abandoned, reason, what was done with the branch.
|
|
99
99
|
|
|
@@ -26,7 +26,7 @@ External sources (tracker, forge, `knowledge`) are all **best-effort**: a CLI mi
|
|
|
26
26
|
|
|
27
27
|
Your **work assistant**: a Scrum-style daily standup — *"what was I working on?"*, *"what's left?"*, *"what should I pick up today?"* — from three sources: **local** work state, the **forge** (open MRs/PRs, reviews, CI), the **tracker** (assigned/re-prioritized tickets). The one overview of every open work; `/flow-work-resume` is the one-branch view. With forge and tracker both unavailable it is still the full local picture.
|
|
28
28
|
|
|
29
|
-
**Read-only.** Never touches `meta.json`, git, the forge, or the tracker; its only writes are the "last seen" marker (§7) and, with `panel.artifact` set, the control-room cards §2 finds stale. What it finds stale it reports and points at the command that writes.
|
|
29
|
+
**Read-only.** Never touches `meta.json`, git, the forge, or the tracker; its only writes are the "last seen" marker (§7) and, with `panel.artifact` set, the control-room cards §2 finds stale — with the `card.json` the panel CLI renders for those works (never their `panel.json`: that is each work's own session's pane). What it finds stale it reports and points at the command that writes.
|
|
30
30
|
|
|
31
31
|
## Modes
|
|
32
32
|
|
|
@@ -88,7 +88,7 @@ cd "$(git rev-parse --show-toplevel)" || exit 1
|
|
|
88
88
|
[ -d "$WORK" ] || { echo "no such folder: $WORK"; exit 1; }
|
|
89
89
|
tmp=$(mktemp -d) || exit 1
|
|
90
90
|
idx="$tmp/index" # does not exist yet: git starts an empty index there
|
|
91
|
-
GIT_INDEX_FILE="$idx" git add -f -- "$WORK" ":(exclude)$WORK/panel.json" &&
|
|
91
|
+
GIT_INDEX_FILE="$idx" git add -f -- "$WORK" ":(exclude)$WORK/panel.json" ":(exclude)$WORK/panel-input.json" ":(exclude)$WORK/card.json" ":(exclude)$WORK/forge-state.json" ":(exclude)$WORK/.panel-refresh*" ":(exclude)$WORK/*.tmp" &&
|
|
92
92
|
files=$(GIT_INDEX_FILE="$idx" git ls-files) &&
|
|
93
93
|
tree=$(GIT_INDEX_FILE="$idx" git write-tree) &&
|
|
94
94
|
commit=$(git commit-tree "$tree" -m "study $TICKET")
|
|
@@ -98,8 +98,9 @@ printf '%s\n' "$files"; echo "commit=$commit"
|
|
|
98
98
|
```
|
|
99
99
|
|
|
100
100
|
`GIT_INDEX_FILE` is set per command, never exported, so a failure leaves no session pointing git
|
|
101
|
-
at a deleted index. `panel.json`
|
|
102
|
-
|
|
101
|
+
at a deleted index. `panel.json`, `panel-input.json`, `card.json`, `forge-state.json`, the `.panel-refresh*` stamps and
|
|
102
|
+
any `*.tmp` stay out: they are this machine's panel, and on
|
|
103
|
+
another one they would show this session's last state as if it were theirs. The block failing → its message, and
|
|
103
104
|
stop: `commit-tree` with no git identity configured is the usual cause.
|
|
104
105
|
|
|
105
106
|
## 4. Confirm, then push
|