@manhquy/flow-skill 0.4.0 → 0.4.1

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
@@ -2,6 +2,11 @@
2
2
 
3
3
  All notable changes to `@manhquy/flow-skill`. Format: [Keep a Changelog](https://keepachangelog.com/en/1.1.0/). Versioning: [SemVer](https://semver.org/).
4
4
 
5
+ ## [0.4.1] — 2026-08-11 — README + CLI help install UX
6
+
7
+ Docs-only installer release (same skill **v0.27.0**). Professional install section, full
8
+ standard-command recipes, `@latest`-only help EXAMPLES, dual-version accuracy.
9
+
5
10
  ## [0.4.0] — 2026-08-11 — ships skill v0.27.0 (harness authority continuity)
6
11
 
7
12
  Skill-content release. Ships skill product **v0.27.0**: flow-owned durable authority,
package/README.md CHANGED
@@ -1,148 +1,167 @@
1
1
  # @manhquy/flow-skill
2
2
 
3
- One-command installer that copies the [flow](https://github.com/manhquydev/flow-skill) skill into your coding agent(s).
3
+ Install the **flow** skill into coding agents with one command.
4
4
 
5
- - Pure Node — works on macOS, Linux, and Windows (cmd, PowerShell 5.1/7, Git Bash) with the same code path.
6
- - Interactive multi-select or non-interactive CI mode.
7
- - Preserves any user-added files in the destination outside the 6 subdirs the skill owns.
8
- - Ships with [npm provenance](https://docs.npmjs.com/generating-provenance-statements) via GitHub Actions trusted publishing **starting with rc.2** — rc.1 was a manual bootstrap because npm Trusted Publisher cannot bind to a package that does not yet exist.
5
+ | | |
6
+ |---|---|
7
+ | **Package** | [`@manhquy/flow-skill`](https://www.npmjs.com/package/@manhquy/flow-skill) (installer CLI) |
8
+ | **Current GA** | **0.4.1** — ships skill product **v0.27.0** |
9
+ | **Platforms** | macOS · Linux · Windows (same Node path) |
10
+ | **Requirement** | Node.js **≥ 22.14** |
11
+ | **Source** | [github.com/manhquydev/flow-skill](https://github.com/manhquydev/flow-skill) |
9
12
 
10
- ## Install
13
+ flow is a gated build harness (`/flow`): idea → honest gates → real done-evidence. This package only **installs** that skill into agent skill homes.
11
14
 
12
- ```
13
- # Newest GA — current: v0.4.0, ships skill v0.27.0
15
+ ---
16
+
17
+ ## Standard install
18
+
19
+ ```bash
20
+ # Recommended — always pin the dist-tag so npx does not reuse a stale cache entry
14
21
  npx @manhquy/flow-skill@latest
15
22
  ```
16
23
 
17
- An interactive prompt asks which agents to install to. Pick one or more, confirm, done.
24
+ | Step | Detail |
25
+ |------|--------|
26
+ | 1 | Fetches **`latest`** from the npm registry |
27
+ | 2 | Interactive multi-select of detected agents (Claude is always offered) |
28
+ | 3 | Copies `skills/flow` into each selected destination |
29
+ | 4 | Prints what to type after reload (`/flow`, `$flow`, …) |
18
30
 
19
- > **Always use `@latest`.** npx caches by bare name, so a plain `npx @manhquy/flow-skill` can
20
- > re-run a stale cached copy; `@latest` forces npx to fetch the newest GA release. See
21
- > [SECURITY.md](./SECURITY.md).
22
- >
23
- > **`npm i` alone is not enough.** `npm install @manhquy/flow-skill` only adds the installer
24
- > package to `node_modules`. You must **run** it (`npx @manhquy/flow-skill@latest` or
25
- > `npx flow-skill` after install) to copy the skill into agent homes.
26
- >
27
- > **Two version axes:** package `version` in this folder is the **installer** (e.g. `0.4.0`).
28
- > Skill product version lives in `skills/flow/SKILL.md` (`metadata.version`, e.g. `0.27.0`).
29
- > `--help` and the JSONL `plan` event expose both (`version` + `skillVersion`).
31
+ **After install:** restart or reload the agent, then invoke flow (see [After install](#after-install)).
30
32
 
31
- ## Non-interactive
33
+ ### Confirm versions
32
34
 
35
+ ```bash
36
+ npx @manhquy/flow-skill@latest --help
37
+ # expect: flow-skill v0.4.x (ships skill v0.27.x)
33
38
  ```
34
- # Default selection (Claude + anything detected)
39
+
40
+ ### Common commands
41
+
42
+ ```bash
43
+ # Non-interactive (Claude + detected agents)
35
44
  npx @manhquy/flow-skill@latest --yes
36
45
 
37
- # Explicit targets
46
+ # One or more targets
47
+ npx @manhquy/flow-skill@latest --yes --target claude
38
48
  npx @manhquy/flow-skill@latest --yes -t claude -t codex
39
- npx @manhquy/flow-skill@latest --yes -t claude,codex # comma form OK
49
+ npx @manhquy/flow-skill@latest --yes -t claude,codex
40
50
 
41
- # Force all five targets even if not detected
51
+ # Every supported target
42
52
  npx @manhquy/flow-skill@latest --yes --all
43
53
 
44
- # Project scope (Claude only — see below)
54
+ # Claude skill inside a project repo (commit-friendly)
45
55
  npx @manhquy/flow-skill@latest --yes --project --dir .
46
56
 
47
- # CI-friendly JSONL output
57
+ # Plan only (no disk writes) + JSONL for CI
48
58
  npx @manhquy/flow-skill@latest --yes --all --dry-run --json
49
59
  ```
50
60
 
51
- ## Targets
61
+ ### Options
52
62
 
53
- | Name | Label | Destination | Detection marker |
54
- |---|---|---|---|
55
- | `claude` | Claude Code | `~/.claude/skills/flow` | any presence of `~/.claude` (Claude is always pre-checked) |
56
- | `codex` | Codex CLI | `~/.codex/skills/flow` | `~/.codex/skills` |
57
- | `agents` | Agents home — also the universal [Agent-Skills](https://agentskills.io) home other spec-compliant tools read | `~/.agents/skills/flow` | `~/.agents/skills` |
58
- | `antigravity` | Antigravity (CLI + IDE) | `~/.gemini/antigravity-cli/skills/flow` **and** `~/.gemini/config/skills/flow` | `~/.gemini/antigravity-cli` **or** `~/.gemini/config/skills` |
59
- | `cursor` | Cursor | `~/.cursor/skills/flow` | `~/.cursor/skills` (never the bare `~/.cursor` config dir every Cursor user has) |
63
+ | Flag | Meaning |
64
+ |------|---------|
65
+ | `-y`, `--yes` | Skip prompts; install default selection (detected + Claude) |
66
+ | `-t`, `--target <name>` | Target (repeatable or comma-separated) |
67
+ | `--all` | All targets, even if not detected |
68
+ | `--project` | Project scope — Claude only → `<dir>/.claude/skills/flow` |
69
+ | `--dir <path>` | Project directory (implies `--project`; default: cwd) |
70
+ | `--json` | JSONL events (`plan`, `install:*`, `summary`) |
71
+ | `--dry-run` | Print plan; do not write |
72
+ | `-h`, `--help` | Help |
60
73
 
61
- `--project` scope writes to `<dir>/.claude/skills/flow` and supports only the `claude` target. Combining `--project` with a non-Claude target exits with code `2`.
74
+ ### Targets
62
75
 
63
- ## After install
76
+ | Name | Destination | Detection |
77
+ |------|-------------|-----------|
78
+ | `claude` | `~/.claude/skills/flow` | `~/.claude` (always offered) |
79
+ | `codex` | `~/.codex/skills/flow` | `~/.codex/skills` |
80
+ | `agents` | `~/.agents/skills/flow` | `~/.agents/skills` |
81
+ | `antigravity` | `~/.gemini/antigravity-cli/skills/flow` **and** `~/.gemini/config/skills/flow` | either path |
82
+ | `cursor` | `~/.cursor/skills/flow` | `~/.cursor/skills` |
64
83
 
65
- A freshly-installed skill isn't discovered by an agent until it reloads — the installer's final
66
- line tells you exactly what to do for whichever targets you installed:
84
+ `--project` supports **only** `claude`. Other targets with `--project` exit `2`.
67
85
 
68
- - Claude Code: type `/flow`.
69
- - Codex CLI: type `$flow` (restart Codex once to load a new skill).
70
- - Antigravity: restart/reload the IDE (or restart `agy`) to load the new skill, then type `/flow`.
71
- - Agents home (`~/.agents/skills/`): restart/reload your tool if it does not auto-detect new skills.
72
- - Cursor: **install verified, live runner execution not yet independently confirmed** — Cursor
73
- has no headless CLI probe available for automated verification (unlike Antigravity's `agy -p`
74
- or Codex's `codex exec`); restart/reload Cursor after install and check the Agent panel for
75
- the `flow` skill.
76
- - Diagnostics: run `/flow doctor` from your agent.
86
+ ### Rules
77
87
 
78
- ## Uninstall
88
+ | Do | Don’t |
89
+ |----|--------|
90
+ | `npx @manhquy/flow-skill@latest` | Bare `npx @manhquy/flow-skill` (stale npx cache) |
91
+ | **Run** the CLI to copy the skill | `npm i` alone (package only; no skill files in agent homes) |
92
+ | Pin installer `@0.4.1` if needed | Pin npm `@0.27.0` (skill version ≠ package version) |
93
+ | Prefer `@latest` | `@rc` (retired / behind) |
79
94
 
80
- Delete the target directories:
95
+ **Two version axes:** `package.json` version = installer; `SKILL.md` metadata = skill product. Both appear in `--help` and in the `plan` JSONL event (`version` + `skillVersion`).
81
96
 
97
+ ---
98
+
99
+ ## After install
100
+
101
+ | Agent | Next step |
102
+ |-------|-----------|
103
+ | Claude Code | Type `/flow` |
104
+ | Codex CLI | Restart Codex once → `$flow` |
105
+ | Antigravity | Restart IDE / `agy` → `/flow` |
106
+ | Agents home | Reload the tool if it does not auto-pick new skills |
107
+ | Cursor | Reload Cursor; confirm `flow` in the agent skills panel |
108
+ | Any | `/flow doctor` (or run `runner/flow.sh doctor`) |
109
+
110
+ ### Verify on disk (Claude global)
111
+
112
+ ```bash
113
+ grep -E '^\s*version:' ~/.claude/skills/flow/SKILL.md | head -1
114
+ bash ~/.claude/skills/flow/runner/flow.sh doctor
82
115
  ```
83
- # Global installs
116
+
117
+ ---
118
+
119
+ ## Uninstall
120
+
121
+ ```bash
84
122
  rm -rf ~/.claude/skills/flow
85
123
  rm -rf ~/.codex/skills/flow
86
124
  rm -rf ~/.agents/skills/flow
125
+ rm -rf ~/.cursor/skills/flow
87
126
  rm -rf ~/.gemini/antigravity-cli/skills/flow
88
127
  rm -rf ~/.gemini/config/skills/flow
89
-
90
- # Project scope (only Claude)
128
+ # project scope:
91
129
  rm -rf <project>/.claude/skills/flow
92
130
  ```
93
131
 
132
+ ---
133
+
94
134
  ## Troubleshooting
95
135
 
96
- - **Windows `EBUSY` / `EPERM` mid-install**: an agent (Claude Code, Codex, Antigravity IDE) is holding a file inside the destination. Close the agent and re-run. The installer already retries with 100/300/900 ms backoff before surfacing the error.
97
- - **Stale advisory lock**: a prior run crashed. The next run detects the dead PID and reclaims the lock automatically. If it does not (very rare — the recorded PID was recycled by another live process), delete `<parent-of-dest>/.flow-skill.installing.lock`.
98
- - **`No matching version found` on `@0.26.0`**: that is the **skill product** version, not the npm package version. Install the installer by its own version (`@latest` / `@0.2.x`) — skill content version is printed by `--help` as `ships skill v…`.
99
- - **Installed package but agent has no `/flow`**: `npm i` does not run the installer. Run `npx @manhquy/flow-skill@latest` (or `npx flow-skill` if already installed) and restart the agent.
100
- - **Node too old** (`requires Node.js >=22.14.0`): upgrade with your preferred version manager (`nvm install 22`, `fnm install 22`, or Node's official installer). Node 20 reached end-of-life April 2026; npm OIDC Trusted Publishing needs npm >=11.5.1 which bundles with Node 22.14+.
136
+ | Symptom | Fix |
137
+ |---------|-----|
138
+ | Agent has no `/flow` after `npm i` | Run `npx @manhquy/flow-skill@latest` (install must **execute**) |
139
+ | Old skill after reinstall | Always use `@latest`; avoid bare package name |
140
+ | `No matching version found` for `@0.27.0` | That is the **skill** version. Use `@latest` or `@0.4.x` |
141
+ | Node too old | Install Node ≥ 22.14 (`nvm install 22`, etc.) |
142
+ | Windows `EBUSY` / `EPERM` | Close the agent holding files under the skill dir; re-run |
143
+ | Stale install lock | Delete `<parent>/.flow-skill.installing.lock` if reclaim fails |
101
144
 
102
- ## JSONL contract
145
+ ---
103
146
 
104
- `--json` streams one JSON object per line:
147
+ ## JSONL (`--json`)
105
148
 
106
149
  ```jsonl
107
- {"event":"plan","version":"0.4.0","skillVersion":"0.27.0","dryRun":false,"scope":"global","targets":["claude","codex"]}
150
+ {"event":"plan","version":"0.4.1","skillVersion":"0.27.0","dryRun":false,"scope":"global","targets":["claude"]}
108
151
  {"event":"install:start","target":"claude","dests":["~/.claude/skills/flow"]}
109
152
  {"event":"install:done","target":"claude","dests":["~/.claude/skills/flow"],"result":"success","error":null,"warnings":[]}
110
- {"event":"summary","success":true,"total":2,"attempted":2,"installed":2,"failed":0,"skipped":0,"aborted":false}
153
+ {"event":"summary","success":true,"total":1,"attempted":1,"installed":1,"failed":0,"skipped":0,"aborted":false}
111
154
  ```
112
155
 
113
- `--json --dry-run` emits only the `plan` event. `--json` implies non-interactive; do not combine with a TTY prompt session.
114
-
115
- ### Event contract
116
-
117
- | Event | Required fields | Notes |
118
- |---|---|---|
119
- | `plan` | `version` (string), `dryRun` (bool), `scope` (`global`\|`project`), `targets` (string[]), optional `skillVersion` (string\|null) | Always the first event. `version` = npm package; `skillVersion` = bundled `SKILL.md` product version. |
120
- | `install:start` | `target` (string), `dests` (string[]) | One per selected target. |
121
- | `install:done` | `target`, `dests`, `result` (`success`\|`failed`), `error` (string\|null), `warnings` (string[]) | Fired after each target. `error` is `null` on success. |
122
- | `summary` | `success` (bool), `total`, `attempted`, `installed`, `failed`, `skipped`, `aborted` (bool) | Always the last event. Counts sum: `attempted = installed + failed`; `skipped = total - attempted`. |
123
- | `error` | `message` (string), `exitCode` (int) | Emitted only when the process crashes before completing a normal flow (e.g. missing bundled skill). Then exits with `exitCode`. |
124
-
125
- Exit codes: `0` success · `1` at least one target failed · `2` invalid usage (bad target name, `--project` with a non-Claude target, missing bundled skill) · `130` `SIGINT` (Ctrl+C).
156
+ Exit codes: `0` success · `1` target failure · `2` bad usage · `130` SIGINT.
126
157
 
127
- The contract is additive within `0.1.x`. New optional fields may appear; existing fields will not be renamed or removed.
128
-
129
- ## Requirements
130
-
131
- - Node.js **>= 22.14.0** — Node 20 reached end-of-life in April 2026, and the publish workflow requires npm >=11.5.1 (bundled with Node 22.14+) for OIDC Trusted Publisher support
132
-
133
- ## Provenance
134
-
135
- Every version published from the CI workflow carries an [npm provenance](https://docs.npmjs.com/generating-provenance-statements) attestation (SLSA Build Level 2). Verify with:
136
-
137
- ```
138
- npm view @manhquy/flow-skill@<version> dist.attestations.provenance
139
- ```
158
+ Contract is additive: new optional fields may appear; existing fields are stable.
140
159
 
141
- > **RC-window exception**: `v0.1.0-rc.1` was published manually from a developer machine to bootstrap npm's Trusted Publisher registration (Trusted Publisher cannot bind to a package that does not exist yet). npm does not generate provenance for publishes outside supported CI. All subsequent versions (`v0.1.0-rc.2` onward) publish through the workflow and are attested.
160
+ ---
142
161
 
143
- ## Security
162
+ ## Provenance & security
144
163
 
145
- See [SECURITY.md](./SECURITY.md) for the threat model, what the installer will and will not do, and how to report issues.
164
+ Published builds from CI include [npm provenance](https://docs.npmjs.com/generating-provenance-statements). Threat model and reporting: [SECURITY.md](./SECURITY.md).
146
165
 
147
166
  ## License
148
167
 
package/README_VN.md CHANGED
@@ -1,128 +1,143 @@
1
1
  # @manhquy/flow-skill
2
2
 
3
- Trình cài đặt một-lệnh sao chép skill [flow](https://github.com/manhquydev/flow-skill) vào (các) coding agent của bạn.
3
+ Cài skill **flow** vào coding agent bằng một lệnh.
4
4
 
5
- - Pure Node — chạy trên macOS, Linux, Windows (cmd, PowerShell 5.1/7, Git Bash) với cùng một code path.
6
- - Multi-select tương tác hoặc chế độ CI không tương tác.
7
- - Bảo toàn file người dùng đã thêm ngoài 6 subdir mà skill sở hữu.
8
- - Ship kèm [npm provenance](https://docs.npmjs.com/generating-provenance-statements) qua GitHub Actions trusted publishing (từ rc.2+).
5
+ | | |
6
+ |---|---|
7
+ | **Package** | [`@manhquy/flow-skill`](https://www.npmjs.com/package/@manhquy/flow-skill) (installer CLI) |
8
+ | **GA hiện tại** | **0.4.1** — ships skill product **v0.27.0** |
9
+ | **Nền tảng** | macOS · Linux · Windows (cùng code path Node) |
10
+ | **Yêu cầu** | Node.js **≥ 22.14** |
11
+ | **Source** | [github.com/manhquydev/flow-skill](https://github.com/manhquydev/flow-skill) |
9
12
 
10
- ## Cài đặt
13
+ flow là harness build có cổng (`/flow`). Package này chỉ **cài** skill đó vào skill home của agent.
11
14
 
12
- ```
13
- # Newest GA — hiện tại: v0.4.0, ships skill v0.27.0
15
+ ---
16
+
17
+ ## Lệnh chuẩn
18
+
19
+ ```bash
20
+ # Khuyến nghị — luôn gắn @latest để npx không dùng cache cũ
14
21
  npx @manhquy/flow-skill@latest
15
22
  ```
16
23
 
17
- Prompt tương tác hỏi cài vào agent nào. Chọn một hoặc nhiều, xác nhận, xong.
24
+ | Bước | Chi tiết |
25
+ |------|----------|
26
+ | 1 | Tải dist-tag **`latest`** từ npm |
27
+ | 2 | Multi-select agent (Claude luôn được đề xuất) |
28
+ | 3 | Copy `skills/flow` vào từng đích |
29
+ | 4 | In hướng dẫn gọi sau reload (`/flow`, `$flow`, …) |
18
30
 
19
- > **Luôn dùng `@latest`.** npx cache theo bare name nên `npx @manhquy/flow-skill` có thể chạy
20
- > bản cache cũ; `@latest` ép lấy GA mới nhất. Kênh `rc` đã retire — không dùng `@rc`.
21
- >
22
- > **`npm i` alone chưa đủ** — phải **chạy** CLI. Hai trục version: package npm vs skill product
23
- > (`ships skill v…` / `skillVersion` trong JSONL). Xem [SECURITY.md](./SECURITY.md).
31
+ **Sau cài:** restart/reload agent (xem [Sau khi cài](#sau-khi-cài)).
24
32
 
25
- ## Non-interactive
33
+ ### Xác nhận version
26
34
 
35
+ ```bash
36
+ npx @manhquy/flow-skill@latest --help
37
+ # expect: flow-skill v0.4.x (ships skill v0.27.x)
27
38
  ```
28
- # Chọn mặc định (Claude + những agent detect được)
39
+
40
+ ### Lệnh hay dùng
41
+
42
+ ```bash
43
+ # Không prompt (Claude + agent đã detect)
29
44
  npx @manhquy/flow-skill@latest --yes
30
45
 
31
46
  # Target rõ ràng
47
+ npx @manhquy/flow-skill@latest --yes --target claude
32
48
  npx @manhquy/flow-skill@latest --yes -t claude -t codex
33
- npx @manhquy/flow-skill@latest --yes -t claude,codex # Dạng comma OK
49
+ npx @manhquy/flow-skill@latest --yes -t claude,codex
34
50
 
35
- # Ép cài cả 5 target dù không detect
51
+ # Cả 5 target
36
52
  npx @manhquy/flow-skill@latest --yes --all
37
53
 
38
- # Project scope (chỉ Claude — xem bên dưới)
54
+ # Skill trong repo (chỉ Claude)
39
55
  npx @manhquy/flow-skill@latest --yes --project --dir .
40
56
 
41
- # JSONL cho CI
57
+ # Chỉ xem kế hoạch + JSONL (CI)
42
58
  npx @manhquy/flow-skill@latest --yes --all --dry-run --json
43
59
  ```
44
60
 
45
- ## Targets
61
+ ### Tùy chọn
46
62
 
47
- | Tên | Nhãn | Đích | Marker phát hiện |
48
- |---|---|---|---|
49
- | `claude` | Claude Code | `~/.claude/skills/flow` | bất kỳ presence của `~/.claude` (Claude luôn pre-check) |
50
- | `codex` | Codex CLI | `~/.codex/skills/flow` | `~/.codex/skills` |
51
- | `agents` | Agents home — cũng là thư mục [Agent-Skills](https://agentskills.io) chung mà các tool tuân chuẩn khác đọc | `~/.agents/skills/flow` | `~/.agents/skills` |
52
- | `antigravity` | Antigravity (CLI + IDE) | `~/.gemini/antigravity-cli/skills/flow` **và** `~/.gemini/config/skills/flow` | `~/.gemini/antigravity-cli` **hoặc** `~/.gemini/config/skills` |
53
- | `cursor` | Cursor | `~/.cursor/skills/flow` | `~/.cursor/skills` (không bao giờ dùng thư mục config `~/.cursor` trần — ai dùng Cursor cũng có) |
63
+ | Flag | Ý nghĩa |
64
+ |------|---------|
65
+ | `-y`, `--yes` | Bỏ prompt; cài selection mặc định |
66
+ | `-t`, `--target <name>` | Target (lặp hoặc comma) |
67
+ | `--all` | Mọi target, kể cả chưa detect |
68
+ | `--project` | Scope project — chỉ Claude → `<dir>/.claude/skills/flow` |
69
+ | `--dir <path>` | Thư mục project (kéo theo `--project`) |
70
+ | `--json` | JSONL events |
71
+ | `--dry-run` | Không ghi đĩa |
72
+ | `-h`, `--help` | Help |
54
73
 
55
- Scope `--project` ghi vào `<dir>/.claude/skills/flow` và chỉ hỗ trợ target `claude`. Kết hợp `--project` với target khác → exit code `2`.
74
+ ### Targets
56
75
 
57
- ## Sau khi cài
58
-
59
- Skill vừa cài xong sẽ không được agent nhận ra cho tới khi agent reload — dòng cuối cùng của
60
- installer nói rõ việc cần làm cho đúng target đã cài:
76
+ | Tên | Đích | Detection |
77
+ |-----|------|-----------|
78
+ | `claude` | `~/.claude/skills/flow` | `~/.claude` |
79
+ | `codex` | `~/.codex/skills/flow` | `~/.codex/skills` |
80
+ | `agents` | `~/.agents/skills/flow` | `~/.agents/skills` |
81
+ | `antigravity` | 2 path dưới `~/.gemini/…` | CLI hoặc IDE skills |
82
+ | `cursor` | `~/.cursor/skills/flow` | `~/.cursor/skills` |
61
83
 
62
- - Claude Code: gõ `/flow`.
63
- - Codex CLI: gõ `$flow` (restart Codex 1 lần để load skill mới).
64
- - Antigravity: restart/reload IDE (hoặc restart `agy`) để load skill mới, rồi gõ `/flow`.
65
- - Agents home: restart/reload tool nếu nó không tự nhận skill mới.
66
- - Cursor: **đã xác nhận cài đúng chỗ, chưa xác nhận runner chạy độc lập** — Cursor không có
67
- CLI headless để tự động kiểm (khác `agy -p` của Antigravity hay `codex exec` của Codex);
68
- restart/reload Cursor sau khi cài rồi kiểm tra panel Agent xem có skill `flow` không.
69
- - Chẩn đoán: chạy `/flow doctor` từ agent.
84
+ `--project` **chỉ** hỗ trợ `claude` (exit `2` nếu kết hợp target khác).
70
85
 
71
- ## Gỡ cài đặt
86
+ ### Quy tắc
72
87
 
73
- Xóa dir target:
88
+ | Nên | Không |
89
+ |-----|--------|
90
+ | `npx @manhquy/flow-skill@latest` | Bare package name (cache npx) |
91
+ | **Chạy** CLI | Chỉ `npm i` |
92
+ | Pin `@0.4.0` nếu cần | Pin `@0.27.0` trên npm (version skill) |
93
+ | `@latest` | `@rc` |
74
94
 
75
- ```
76
- # Global installs
77
- rm -rf ~/.claude/skills/flow
78
- rm -rf ~/.codex/skills/flow
79
- rm -rf ~/.agents/skills/flow
80
- rm -rf ~/.gemini/antigravity-cli/skills/flow
81
- rm -rf ~/.gemini/config/skills/flow
82
-
83
- # Project scope (chỉ Claude)
84
- rm -rf <project>/.claude/skills/flow
85
- ```
95
+ **Hai trục version:** package = installer; skill = `SKILL.md`. Cả hai hiện trong `--help` và event `plan` (`version` + `skillVersion`).
86
96
 
87
- ## JSONL contract
97
+ ---
88
98
 
89
- `--json` stream một JSON object mỗi dòng. Xem [README.md § JSONL contract](./README.md#jsonl-contract) cho bảng đầy đủ event/field/exit code. Tóm tắt:
90
-
91
- - `plan` — event đầu tiên; chứa `version`, `dryRun`, `scope`, `targets`.
92
- - `install:start` / `install:done` — một cặp mỗi target; `install:done.result` = `success` hoặc `failed`.
93
- - `summary` — event cuối cùng; `success`, `total`, `attempted`, `installed`, `failed`, `skipped`, `aborted`.
94
- - Exit codes: `0` OK · `1` ≥1 target fail · `2` sai flag/target · `130` Ctrl+C.
95
-
96
- Hợp đồng additive trong `0.1.x` — field mới có thể thêm, field cũ không rename/xóa.
97
-
98
- ## Troubleshooting
99
+ ## Sau khi cài
99
100
 
100
- - **`EBUSY`/`EPERM` giữa install trên Windows**: một agent đang giữ handle vào file trong destination. Đóng agent + re-run. Installer đã retry 100/300/900 ms trước khi báo error.
101
- - **Advisory lock cũ**: run trước crash. Run mới tự phát hiện PID dead → reclaim. Trường hợp hiếm (PID được recycle bởi process khác đang chạy): xóa `<parent-of-dest>/.flow-skill.installing.lock`.
102
- - **`No matching version found` với `@0.24.0`**: đó là version **skill product**, không phải version npm package. Cài installer theo version của nó (bare / `@0.1.x` / `@rc`) — version skill in ra ở `--help` (`ships skill v…`).
103
- - **Node quá cũ** (`requires Node.js >=22.14.0`): update bằng `nvm install 22`, `fnm install 22`, hoặc installer chính thức của Node. Node 20 hết vòng đời từ 4/2026; npm OIDC Trusted Publishing cần npm >=11.5.1 (bundle theo Node 22.14+).
101
+ | Agent | Bước tiếp |
102
+ |-------|-----------|
103
+ | Claude Code | Gõ `/flow` |
104
+ | Codex | Restart Codex → `$flow` |
105
+ | Antigravity | Restart IDE/`agy` → `/flow` |
106
+ | Agents / Cursor | Reload tool; kiểm panel skill |
107
+ | Bất kỳ | `/flow doctor` |
108
+
109
+ ```bash
110
+ grep -E '^\s*version:' ~/.claude/skills/flow/SKILL.md | head -1
111
+ bash ~/.claude/skills/flow/runner/flow.sh doctor
112
+ ```
104
113
 
105
- ## Yêu cầu
114
+ ---
106
115
 
107
- - Node.js **>= 22.14.0** — Node 20 hết vòng đời từ 4/2026, và publish workflow cần npm >=11.5.1 (bundle theo Node 22.14+) cho OIDC Trusted Publisher
116
+ ## Gỡ cài
108
117
 
109
- ## Provenance
118
+ ```bash
119
+ rm -rf ~/.claude/skills/flow ~/.codex/skills/flow ~/.agents/skills/flow
120
+ rm -rf ~/.cursor/skills/flow
121
+ rm -rf ~/.gemini/antigravity-cli/skills/flow ~/.gemini/config/skills/flow
122
+ rm -rf <project>/.claude/skills/flow
123
+ ```
110
124
 
111
- Mỗi phiên bản publish có [npm provenance](https://docs.npmjs.com/generating-provenance-statements) attestation. Verify:
125
+ ---
112
126
 
113
- ```
114
- npm view @manhquy/flow-skill@<version> dist.attestations.provenance
115
- ```
127
+ ## Xử lý sự cố
116
128
 
117
- > **Ngoại lệ RC-window**: `v0.1.0-rc.1` được publish thủ công từ máy developer để bootstrap npm
118
- > Trusted Publisher (TP không thể bind tới package chưa tồn tại) — bản này không có provenance.
119
- > Từ `v0.1.0-rc.2` trở đi, mọi bản publish đều qua CI workflow với OIDC và có attestation
120
- > SLSA Build Level 2 đầy đủ.
129
+ | Hiện tượng | Cách xử lý |
130
+ |------------|------------|
131
+ | Có package nhưng không có `/flow` | Chạy `npx @manhquy/flow-skill@latest` |
132
+ | Skill cũ sau khi “cài lại” | Luôn `@latest` |
133
+ | `No matching version` với `@0.27.0` | Dùng `@latest` / `@0.4.x` (version skill ≠ package) |
134
+ | Node quá cũ | Nâng Node ≥ 22.14 |
135
+ | Windows EBUSY | Đóng agent đang giữ file skill; chạy lại |
121
136
 
122
- ## Bảo mật
137
+ ---
123
138
 
124
- Threat model + WILL/WON'T list + kênh report — xem [SECURITY.md](./SECURITY.md). Tóm tắt: pure Node, không network call, không spawn shell/PowerShell, không postinstall hook, không chạm settings/hooks/MCP config.
139
+ ## JSONL · provenance · license
125
140
 
126
- ## License
141
+ Xem bản [English README](./README.md) cho bảng event JSONL, provenance, và [SECURITY.md](./SECURITY.md).
127
142
 
128
143
  MIT © 2026 manhquy
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@manhquy/flow-skill",
3
- "version": "0.4.0",
3
+ "version": "0.4.1",
4
4
  "description": "Install the flow skill (buildflow gated build process) into your coding agent(s) via one npx command",
5
5
  "type": "module",
6
6
  "bin": {
@@ -2,7 +2,7 @@
2
2
  "source": "../skills/flow",
3
3
  "destRelative": "skills/flow",
4
4
  "fileCount": 84,
5
- "syncedAt": "2026-08-11T07:44:16.437Z",
5
+ "syncedAt": "2026-08-11T08:09:29.734Z",
6
6
  "fileList": [
7
7
  "SKILL.md",
8
8
  "_templates/00-idea.md",
package/src/help.mjs CHANGED
@@ -2,8 +2,6 @@ import { CLI_NAME, PKG_VERSION, SKILL_VERSION, TARGETS } from './constants.mjs';
2
2
 
3
3
  export function renderHelp() {
4
4
  const targetRows = TARGETS.map((t) => ` ${t.name.padEnd(12)} ${t.label}`).join('\n');
5
- // v0.23 H5 (red-team): derive the count from TARGETS.length so a future target addition can
6
- // never again leave a stale hardcoded number in the help text.
7
5
  const targetCount = TARGETS.length;
8
6
  const skillBit = SKILL_VERSION ? ` (ships skill v${SKILL_VERSION})` : '';
9
7
  return `${CLI_NAME} v${PKG_VERSION}${skillBit}
@@ -12,7 +10,9 @@ Install the flow skill into your coding agent(s).
12
10
 
13
11
  USAGE
14
12
  npx @manhquy/flow-skill@latest
15
- # or after stable ships: npx @manhquy/flow-skill
13
+
14
+ Always use @latest so npx fetches the newest release.
15
+ Bare "npx @manhquy/flow-skill" may reuse a stale cache.
16
16
 
17
17
  OPTIONS
18
18
  -y, --yes Skip prompts; install to default selection (detected + Claude)
@@ -28,20 +28,18 @@ TARGETS
28
28
  ${targetRows}
29
29
 
30
30
  Notes:
31
- - Antigravity target writes 2 destinations: ~/.gemini/antigravity-cli/skills/flow AND ~/.gemini/config/skills/flow.
32
- - Agents home (~/.agents/skills/) is the universal Agent-Skills home — the open standard
33
- (agentskills.io) directory that spec-compliant tools beyond this installer's named targets
34
- (e.g. Cursor also reads it) can pick up from.
35
- - --project scope supports only "claude" (agent-contract limitation).
36
- - Non-detected targets can still be forced via --target or --all.
31
+ - Antigravity writes 2 destinations (CLI + IDE skill homes).
32
+ - --project supports only "claude".
33
+ - "npm i" alone does not install the skill — you must run this CLI.
34
+ - Installer version (this package) ≠ skill product version (SKILL.md).
37
35
 
38
36
  EXAMPLES
39
- npx @manhquy/flow-skill # interactive multi-select
40
- npx @manhquy/flow-skill --yes # non-interactive; default selection
41
- npx @manhquy/flow-skill --yes --all # force all ${targetCount} targets
42
- npx @manhquy/flow-skill --yes -t claude -t codex # explicit targets
43
- npx @manhquy/flow-skill --project --dir . # project-scoped install (Claude only)
44
- npx @manhquy/flow-skill --yes --all --dry-run --json # CI JSONL preview
37
+ npx @manhquy/flow-skill@latest
38
+ npx @manhquy/flow-skill@latest --yes
39
+ npx @manhquy/flow-skill@latest --yes --all
40
+ npx @manhquy/flow-skill@latest --yes -t claude -t codex
41
+ npx @manhquy/flow-skill@latest --yes --project --dir .
42
+ npx @manhquy/flow-skill@latest --yes --all --dry-run --json
45
43
 
46
44
  MORE
47
45
  Docs: https://github.com/manhquydev/flow-skill#readme