mustflow 2.25.2 → 2.27.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/package.json +1 -1
- package/templates/default/i18n.toml +19 -1
- package/templates/default/locales/en/.mustflow/skills/INDEX.md +4 -1
- package/templates/default/locales/en/.mustflow/skills/bun-code-change/SKILL.md +143 -0
- package/templates/default/locales/en/.mustflow/skills/docker-code-change/SKILL.md +262 -0
- package/templates/default/locales/en/.mustflow/skills/node-code-change/SKILL.md +145 -0
- package/templates/default/locales/en/.mustflow/skills/routes.toml +18 -0
- package/templates/default/manifest.toml +22 -1
package/package.json
CHANGED
|
@@ -56,7 +56,7 @@ translations = {}
|
|
|
56
56
|
[documents."skills.index"]
|
|
57
57
|
source = "locales/en/.mustflow/skills/INDEX.md"
|
|
58
58
|
source_locale = "en"
|
|
59
|
-
revision =
|
|
59
|
+
revision = 89
|
|
60
60
|
translations = {}
|
|
61
61
|
|
|
62
62
|
[documents."skill.adapter-boundary"]
|
|
@@ -191,6 +191,12 @@ source_locale = "en"
|
|
|
191
191
|
revision = 2
|
|
192
192
|
translations = {}
|
|
193
193
|
|
|
194
|
+
[documents."skill.bun-code-change"]
|
|
195
|
+
source = "locales/en/.mustflow/skills/bun-code-change/SKILL.md"
|
|
196
|
+
source_locale = "en"
|
|
197
|
+
revision = 1
|
|
198
|
+
translations = {}
|
|
199
|
+
|
|
194
200
|
[documents."skill.cpp-code-change"]
|
|
195
201
|
source = "locales/en/.mustflow/skills/cpp-code-change/SKILL.md"
|
|
196
202
|
source_locale = "en"
|
|
@@ -203,6 +209,12 @@ source_locale = "en"
|
|
|
203
209
|
revision = 2
|
|
204
210
|
translations = {}
|
|
205
211
|
|
|
212
|
+
[documents."skill.docker-code-change"]
|
|
213
|
+
source = "locales/en/.mustflow/skills/docker-code-change/SKILL.md"
|
|
214
|
+
source_locale = "en"
|
|
215
|
+
revision = 1
|
|
216
|
+
translations = {}
|
|
217
|
+
|
|
206
218
|
[documents."skill.elysia-code-change"]
|
|
207
219
|
source = "locales/en/.mustflow/skills/elysia-code-change/SKILL.md"
|
|
208
220
|
source_locale = "en"
|
|
@@ -239,6 +251,12 @@ source_locale = "en"
|
|
|
239
251
|
revision = 2
|
|
240
252
|
translations = {}
|
|
241
253
|
|
|
254
|
+
[documents."skill.node-code-change"]
|
|
255
|
+
source = "locales/en/.mustflow/skills/node-code-change/SKILL.md"
|
|
256
|
+
source_locale = "en"
|
|
257
|
+
revision = 1
|
|
258
|
+
translations = {}
|
|
259
|
+
|
|
242
260
|
[documents."skill.python-code-change"]
|
|
243
261
|
source = "locales/en/.mustflow/skills/python-code-change/SKILL.md"
|
|
244
262
|
source_locale = "en"
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
mustflow_doc: skills.index
|
|
3
3
|
locale: en
|
|
4
4
|
canonical: true
|
|
5
|
-
revision:
|
|
5
|
+
revision: 89
|
|
6
6
|
authority: router
|
|
7
7
|
lifecycle: mustflow-owned
|
|
8
8
|
---
|
|
@@ -101,6 +101,9 @@ routes. Event routes stay inactive until their event occurs.
|
|
|
101
101
|
| A coding task has missing intent, scope, domain, data, security, UX, dependency, architecture, or verification decisions that cannot be safely inferred from repository evidence | `.mustflow/skills/clarifying-question-gate/SKILL.md` | User request, inspected repository evidence, unresolved decisions, reversibility classification, recommended option, and tradeoffs | Blocking questions, safe assumptions, and the smallest safe implementation boundary | over-questioning, lazy questions, expensive wrong assumptions, user-owned decision drift, data loss, auth bypass, public-contract drift, dependency bloat, or unverifiable completion | `changes_status`, `changes_diff_summary`, `mustflow_check` | Repository evidence inspected, blocking questions with recommendations, safe assumptions, selected scope, verification, and remaining ambiguity |
|
|
102
102
|
| HTTP, REST, GraphQL, tRPC, Hono RPC, Elysia Eden, gRPC, protobuf, OpenAPI, request/response schema, status code, header, error envelope, pagination, filtering, sorting, search, generated client, SDK, mock, fixture, or API docs contract is created or changed | `.mustflow/skills/api-contract-change/SKILL.md` | API style, contract source of truth, changed operations, request and response schemas, status and headers, error envelope, auth and permission behavior, pagination/filter/sort/search semantics, generated clients, SDKs, mocks, fixtures, callers, docs, and command contract entries | Routes, handlers, resolvers, validators, schemas, generated clients, SDKs, mocks, fixtures, docs, tests, and directly synchronized examples | route-only change, schema drift, generated-client breakage, hidden breaking change, status or error drift, pagination/search semantic drift, auth/permission drift, or stale docs examples | `changes_status`, `changes_diff_summary`, `lint`, `build`, `test_related`, `test`, `docs_validate_fast`, `test_release`, `mustflow_check` | API contract source, changed operations, compatibility classification, synchronized client/schema/docs/tests surfaces, verification, and remaining API contract risk |
|
|
103
103
|
| C++ source, headers, modules, native build metadata, toolchains, package managers, public headers, shared or static libraries, ABI surfaces, generated bindings, FFI, tests, or benchmarks are created or changed | `.mustflow/skills/cpp-code-change/SKILL.md` | Owning target, compilation identity, build front door, changed consumed surface, public API/ABI/FFI/binding surfaces, ownership and lifetime contracts, and command contract entries | C++ source, headers, modules, build metadata, package metadata, generated bindings, FFI code, tests, benchmarks, and directly synchronized docs | target drift, source API break, binary ABI break, undefined behavior, lifetime bug, build-graph drift, generated-binding drift, FFI memory bug, unverified modern C++ feature, or false performance claim | `changes_status`, `changes_diff_summary`, `lint`, `build`, `test_related`, `test`, `docs_validate_fast`, `test_release`, `mustflow_check` | Owning target, compilation identity, highest compatibility risk, ownership/lifetime/UB/concurrency notes, public API/ABI/FFI/binding impact, verification, and remaining C++ risk |
|
|
104
|
+
| Node.js runtime code, package manager ownership, module format, package entry metadata, native dependencies, Node test runner behavior, TypeScript execution mode, or deployment runtime support is created or changed | `.mustflow/skills/node-code-change/SKILL.md` | Node version signals, package manager and lockfile owner, module/package metadata, TypeScript loader, test runner, native dependency, deployment target, and command contract entries | Node runtime code, package metadata, lockfiles, scripts, CI or Docker runtime declarations, test runner config, native dependency handling, docs examples, and directly synchronized package surfaces | newest-Node assumption, package manager drift, ESM/CJS break, blocked deep import, native dependency break, Node native TypeScript overclaim, test runner migration risk, deployment mismatch, or permission-model overclaim | `changes_status`, `changes_diff_summary`, `lint`, `build`, `test_related`, `test`, `docs_validate_fast`, `test_release`, `mustflow_check` | Runtime and package manager decision, module/package entry notes, TypeScript/test runner notes, native/deployment risks, verification, and remaining Node.js risk |
|
|
105
|
+
| Bun runtime code, Bun package manager behavior, `bun.lock`, `bunfig.toml`, Bun test runner behavior, Bun bundling, Bun TypeScript execution, or Bun-specific APIs are created or changed | `.mustflow/skills/bun-code-change/SKILL.md` | Bun role signals, `package.json`, Bun and non-Bun lockfiles, `bunfig.toml`, CI/Docker Bun setup, TypeScript config, Bun APIs, native dependency signals, and command contract entries | Bun runtime code, Bun package manager metadata, lockfiles, `bunfig.toml`, scripts, tests, bundler config, TypeScript/declaration pipeline, package metadata, and directly synchronized docs | Bun role confusion, lockfile drift, trusted dependency overgrant, runtime/package-manager conflation, Bun TypeScript typecheck overclaim, Bun build declaration gap, Node compatibility break, shebang mismatch, or native binary break | `changes_status`, `changes_diff_summary`, `lint`, `build`, `test_related`, `test`, `docs_validate_fast`, `test_release`, `mustflow_check` | Bun role classification, lockfile/trust notes, runtime/type/build/test notes, Node compatibility risks, verification, and remaining Bun risk |
|
|
106
|
+
| Dockerfiles, `.dockerignore`, Docker Compose files, BuildKit or buildx behavior, container image metadata, tags, entrypoints, health checks, Docker CI workflows, image security scanning, SBOM or provenance settings, registry publishing, or container runtime validation are created or changed | `.mustflow/skills/docker-code-change/SKILL.md` | Docker surfaces, project image shape, base image and platform signals, build context and cache signals, runtime contract, security and supply-chain contract, and command contract entries | Dockerfiles, `.dockerignore`, Compose files, container CI workflow snippets, image metadata, package tests, docs examples, template metadata, and directly synchronized skill routes | cache breakage, secret leak, root runtime, host access escape, dev dependency in final image, mutable tag drift, untrusted CI publish, missing SBOM/provenance, unverified runtime, or false production-readiness claim | `changes_status`, `changes_diff_summary`, `lint`, `build`, `test_related`, `test`, `docs_validate_fast`, `test_release`, `mustflow_check` | Docker surface classification, image/base/cache/stage decisions, secret/user/runtime/Compose/CI supply-chain notes, verification, and remaining Docker risk |
|
|
104
107
|
| TypeScript source, declarations, tsconfig, package exports, module resolution, public API, or TypeScript tests are created or changed | `.mustflow/skills/typescript-code-change/SKILL.md` | TypeScript config, package entry metadata, target runtime, changed files, and command contract entries | TypeScript source, declarations, compiler config, exports, tests, and directly synchronized docs | weakened type safety, module drift, public API drift, or unverified declaration output | `changes_status`, `changes_diff_summary`, `lint`, `build`, `test_related`, `test`, `docs_validate_fast`, `mustflow_check` | Runtime, module, type, and public API boundary checked, changes made, verification, and remaining TypeScript risk |
|
|
105
108
|
| JavaScript source, module format, package entry, browser or Node runtime, dependency usage, Promise handling, bundler config, or JavaScript tests are created or changed | `.mustflow/skills/javascript-code-change/SKILL.md` | Package metadata, module system, runtime target, entrypoints, changed files, and command contract entries | JavaScript source, package exports, bundler config, dependencies, tests, and docs examples | runtime API leakage, ESM/CJS drift, discarded Promise, dependency bloat, or broken package entry | `changes_status`, `changes_diff_summary`, `lint`, `build`, `test_related`, `test`, `docs_validate_fast`, `mustflow_check` | Runtime and module boundary checked, async and dependency notes, verification, and remaining JavaScript risk |
|
|
106
109
|
| Python source, package metadata, runtime version, import layout, type checking, linting, CLI entry points, or tests are created or changed | `.mustflow/skills/python-code-change/SKILL.md` | Python version source, packaging files, import layout, lint/type/test config, changed files, and command contract entries | Python source, packaging metadata, imports, type hints, tests, and docs examples | unsupported syntax, import hacks, packaging drift, swallowed errors, or weakened lint/type checks | `changes_status`, `changes_diff_summary`, `lint`, `build`, `test_related`, `test`, `docs_validate_fast`, `mustflow_check` | Runtime, packaging, import, and type boundary checked, verification, and remaining Python risk |
|
|
@@ -0,0 +1,143 @@
|
|
|
1
|
+
---
|
|
2
|
+
mustflow_doc: skill.bun-code-change
|
|
3
|
+
locale: en
|
|
4
|
+
canonical: true
|
|
5
|
+
revision: 1
|
|
6
|
+
lifecycle: mustflow-owned
|
|
7
|
+
authority: procedure
|
|
8
|
+
name: bun-code-change
|
|
9
|
+
description: Apply this skill when Bun runtime code, Bun package manager behavior, bun.lock, bunfig.toml, Bun test runner behavior, Bun bundling, Bun TypeScript execution, or Bun-specific APIs are created or changed.
|
|
10
|
+
metadata:
|
|
11
|
+
mustflow_schema: "1"
|
|
12
|
+
mustflow_kind: procedure
|
|
13
|
+
pack_id: mustflow.core
|
|
14
|
+
skill_id: mustflow.core.bun-code-change
|
|
15
|
+
command_intents:
|
|
16
|
+
- changes_status
|
|
17
|
+
- changes_diff_summary
|
|
18
|
+
- lint
|
|
19
|
+
- build
|
|
20
|
+
- test_related
|
|
21
|
+
- test
|
|
22
|
+
- docs_validate_fast
|
|
23
|
+
- test_release
|
|
24
|
+
- mustflow_check
|
|
25
|
+
---
|
|
26
|
+
|
|
27
|
+
# Bun Code Change
|
|
28
|
+
|
|
29
|
+
<!-- mustflow-section: purpose -->
|
|
30
|
+
## Purpose
|
|
31
|
+
|
|
32
|
+
Preserve Bun's separate roles as runtime, package manager, script runner, test runner, bundler, transpiler, and Node-compatible environment without mistaking one successful role for another.
|
|
33
|
+
|
|
34
|
+
<!-- mustflow-section: use-when -->
|
|
35
|
+
## Use When
|
|
36
|
+
|
|
37
|
+
- `bun.lock`, `bun.lockb`, `bunfig.toml`, `packageManager: "bun@..."`, Bun install settings, `trustedDependencies`, Bun workspace behavior, or Bun lockfile migration changes.
|
|
38
|
+
- Bun runtime code or config changes, including `Bun.*`, `Bun.serve`, `Bun.file`, `Bun.write`, `Bun.spawn`, `Bun.$`, `bun:sqlite`, `#!/usr/bin/env bun`, Bun preload, Bun `.env` behavior, or `bun run --bun`.
|
|
39
|
+
- Bun test runner behavior changes, including `bun test`, `bun:test`, `[test]` in `bunfig.toml`, snapshots, mocks, preload, isolation, coverage, sharding, or parallelism.
|
|
40
|
+
- Bun bundling, compile, transpiler, build target, JSX settings, path aliases, TypeScript runtime execution, or library packaging with Bun changes.
|
|
41
|
+
|
|
42
|
+
<!-- mustflow-section: do-not-use-when -->
|
|
43
|
+
## Do Not Use When
|
|
44
|
+
|
|
45
|
+
- Bun appears only as the local command used by mustflow's configured command intents, and the changed project surface is not Bun-specific.
|
|
46
|
+
- The task changes generic TypeScript type modeling or declaration surfaces without Bun runtime, bundler, package manager, or test runner behavior; use `typescript-code-change`.
|
|
47
|
+
- The task changes generic JavaScript without Bun ownership; use `javascript-code-change`.
|
|
48
|
+
- Elysia route, schema, plugin, OpenAPI, or Eden behavior is the main surface; use `elysia-code-change` first and this skill only for Bun runtime or tooling risks.
|
|
49
|
+
|
|
50
|
+
<!-- mustflow-section: required-inputs -->
|
|
51
|
+
## Required Inputs
|
|
52
|
+
|
|
53
|
+
- `package.json` fields: `packageManager`, `scripts`, `workspaces`, `trustedDependencies`, `overrides`, `resolutions`, `patchedDependencies`, `dependencies`, `devDependencies`, `optionalDependencies`, and package entry metadata.
|
|
54
|
+
- Bun ownership files: `bun.lock`, `bun.lockb`, `bunfig.toml`, npm, pnpm, or Yarn lockfiles that coexist with Bun, CI install commands, Docker install and runtime commands, and `oven-sh/setup-bun` usage.
|
|
55
|
+
- Bun config sections: `[install]`, `[test]`, top-level preload, env, define, loader, JSX, and run settings.
|
|
56
|
+
- Runtime and compatibility surfaces: `Bun.*`, `bun:test`, `node:*`, `.node`, `node-gyp`, lifecycle scripts, Prisma, sharp, Playwright, esbuild, native binary packages, streams, workers, child processes, crypto, filesystem watch, and shebangs.
|
|
57
|
+
- TypeScript and package surfaces: `tsconfig*.json`, `@types/bun`, `types: ["bun"]`, module resolution, path aliases, JSX runtime, declaration output, build targets, package exports, and command contract entries.
|
|
58
|
+
|
|
59
|
+
<!-- mustflow-section: preconditions -->
|
|
60
|
+
## Preconditions
|
|
61
|
+
|
|
62
|
+
- Classify Bun's role before editing. Bun may be only the package manager, only the script runner, only the test runner, only the bundler, the runtime, or several of these at once.
|
|
63
|
+
- Do not treat Bun package installation as proof that Bun runtime behavior works.
|
|
64
|
+
- Do not treat Bun runtime execution, Bun transpilation, Bun tests, or Bun bundling as TypeScript typechecking or declaration generation.
|
|
65
|
+
- Treat lockfile, trusted dependency, build target, and package entry changes as release-sensitive unless proven internal.
|
|
66
|
+
|
|
67
|
+
<!-- mustflow-section: allowed-edits -->
|
|
68
|
+
## Allowed Edits
|
|
69
|
+
|
|
70
|
+
- Keep Bun-specific APIs in Bun-owned runtime files, adapters, tests, or package entrypoints.
|
|
71
|
+
- Keep Bun package manager changes aligned with `bun.lock`, `bunfig.toml`, CI, Docker, and workspace ownership.
|
|
72
|
+
- Preserve existing Node, browser, edge, Jest, Vitest, TypeScript, and package-consumer contracts unless the task explicitly asks to migrate them.
|
|
73
|
+
- Add focused tests or package checks only when they protect changed Bun runtime, package manager, test runner, build, or public package behavior.
|
|
74
|
+
|
|
75
|
+
<!-- mustflow-section: procedure -->
|
|
76
|
+
## Procedure
|
|
77
|
+
|
|
78
|
+
1. Classify every Bun signal by role before editing:
|
|
79
|
+
- `bun install`, `bun add`, `bun remove`, `bun update`, `bun.lock`, `trustedDependencies`, and `[install]` are package manager signals.
|
|
80
|
+
- `bun <file>`, `bun --watch`, `bun run --bun`, `#!/usr/bin/env bun`, `Bun.serve`, `Bun.file`, `Bun.write`, `Bun.spawn`, `Bun.$`, and preload settings are runtime signals.
|
|
81
|
+
- `bun test`, `bun:test`, and `[test]` are test runner signals.
|
|
82
|
+
- `bun build`, `Bun.build`, `--compile`, and build target settings are bundler or compiler signals.
|
|
83
|
+
- `bun run <script>` is script execution until the script body proves a more specific role.
|
|
84
|
+
2. Determine package manager ownership from `packageManager`, Bun lockfiles, other lockfiles, CI, Docker, workspace config, and `bunfig.toml`. If `bun.lock` exists, treat Bun as the dependency owner unless current project evidence says otherwise.
|
|
85
|
+
3. Do not delete `bun.lockb`, create `bun.lock`, or switch between npm, pnpm, Yarn, and Bun lockfiles as a side effect. If multiple lockfiles exist, identify whether the state is migration, legacy compatibility, or intentional parallel ownership before editing dependencies.
|
|
86
|
+
4. For Bun installs, check frozen lockfile behavior, workspace filters, linker mode, global virtual store, cache settings, registry settings, overrides, resolutions, patched dependencies, peer dependency behavior, optional dependency behavior, OS, CPU, and libc-sensitive packages when relevant.
|
|
87
|
+
5. Treat `trustedDependencies` as install-time code execution policy. Omitted, explicit array, and empty array each have different trust semantics. Do not broaden trust with a generic trust-all action. If a native package or binary install fails, inspect blocked lifecycle scripts, trust only the required package, and verify with a fresh install and real import or CLI use when a configured intent exists.
|
|
88
|
+
6. Do not claim Bun runs TypeScript as typecheck. Bun runtime execution and `Bun.Transpiler` strip or transform syntax for execution; they do not run the TypeScript checker, emit declarations, or prove generic, JSX, path alias, or public type correctness.
|
|
89
|
+
7. Do not claim Bun bundling replaces TypeScript build output. Bun build output proves bundling for the selected target and format, not `tsc --noEmit`, declaration emit, or downstream TypeScript consumer compatibility.
|
|
90
|
+
8. For TypeScript changes in a Bun project, keep the existing typecheck intent and declaration pipeline. For libraries, inspect declaration output when package exports, path aliases, public types, or build output change. Source-only aliases must not leak into public declarations unless consumers can resolve them.
|
|
91
|
+
9. Align Bun and TypeScript JSX settings when JSX runtime, factory, fragment, or import source changes. TypeScript seeing one JSX runtime while Bun transpiles another is a runtime contract bug.
|
|
92
|
+
10. For Bun bundling and package output, distinguish `bun run build` from direct Bun bundler usage. Confirm script bodies before treating a build as Bun bundling. Choose target and format according to actual consumers; Bun-targeted output is not automatically Node-compatible.
|
|
93
|
+
11. If Node consumers are supported, do not emit package entrypoints that rely on Bun-only APIs, Bun-only wrappers, or Bun-only module resolution unless the package clearly exposes a Bun-specific entry.
|
|
94
|
+
12. Treat Bun runtime as Node-compatible, not Node itself. JavaScriptCore, Node API compatibility gaps, native addons, Node internals, worker options, child process IPC, stream/backpressure, crypto/FIPS, watch behavior, Prisma CLI, sharp, Playwright, and esbuild all need targeted evidence when touched.
|
|
95
|
+
13. Check shebang and runner behavior. A CLI with `#!/usr/bin/env node` may execute under Node even when launched through Bun. Do not call a path Bun-runtime-verified unless the entrypoint actually ran under Bun.
|
|
96
|
+
14. Use Bun's test runner only when the project intentionally uses it or the task targets Bun. Do not silently migrate Jest or Vitest tests to `bun:test`. Treat mocks, snapshots, preloads, globals, path aliases, coverage, isolation, and parallelism as migration-risk areas.
|
|
97
|
+
15. Do not update Bun snapshots as a generic fix. Snapshot updates require intended output change, diff inspection, and a follow-up run without update mode through configured intents.
|
|
98
|
+
16. Choose configured verification intents that cover typecheck, build, tests, package metadata, package artifact risk, docs examples, Bun runtime behavior, Bun test behavior, and mustflow contract checks when available. Report missing frozen install, Bun runtime, Bun test, declaration, package artifact, native dependency, Node compatibility, Docker, or CI verification.
|
|
99
|
+
|
|
100
|
+
<!-- mustflow-section: postconditions -->
|
|
101
|
+
## Postconditions
|
|
102
|
+
|
|
103
|
+
- Bun's role is explicit: package manager, runtime, script runner, test runner, bundler, transpiler, or mixed.
|
|
104
|
+
- Bun lockfile, install, workspace, trust, and lifecycle behavior is aligned with project ownership.
|
|
105
|
+
- Bun runtime, test, bundler, TypeScript, and declaration claims are not conflated.
|
|
106
|
+
- Bun-only APIs do not leak into Node, browser, edge, or shared package surfaces unintentionally.
|
|
107
|
+
- Native dependency, shebang, Node compatibility, and package consumer risks are handled or reported.
|
|
108
|
+
|
|
109
|
+
<!-- mustflow-section: verification -->
|
|
110
|
+
## Verification
|
|
111
|
+
|
|
112
|
+
Use configured oneshot command intents when available:
|
|
113
|
+
|
|
114
|
+
- `lint`
|
|
115
|
+
- `build`
|
|
116
|
+
- `test_related`
|
|
117
|
+
- `test`
|
|
118
|
+
- `docs_validate_fast`
|
|
119
|
+
- `test_release`
|
|
120
|
+
- `mustflow_check`
|
|
121
|
+
|
|
122
|
+
Report missing frozen install, Bun runtime, Bun test, declaration output, package artifact, Node compatibility, native dependency, CI, Docker, or snapshot review verification intents when those surfaces change.
|
|
123
|
+
|
|
124
|
+
<!-- mustflow-section: failure-handling -->
|
|
125
|
+
## Failure Handling
|
|
126
|
+
|
|
127
|
+
- If Bun's role is unclear, stop changing runtime or dependency behavior and inspect scripts, lockfiles, `bunfig.toml`, CI, Docker, and entrypoints.
|
|
128
|
+
- If lockfile ownership conflicts, do not run dependency migration or generate a new lockfile unless the task explicitly asks for migration.
|
|
129
|
+
- If Bun runtime execution succeeds but typecheck or declarations are unverified, report that gap instead of claiming TypeScript correctness.
|
|
130
|
+
- If a package works under Bun but claims Node support, repair the Node-compatible entry or report the compatibility risk.
|
|
131
|
+
- If a native dependency, lifecycle script, or trusted dependency change cannot be verified, keep the change scoped and report release-sensitive risk.
|
|
132
|
+
|
|
133
|
+
<!-- mustflow-section: output-format -->
|
|
134
|
+
## Output Format
|
|
135
|
+
|
|
136
|
+
- Bun role classification
|
|
137
|
+
- Package manager, lockfile, and trust notes
|
|
138
|
+
- Runtime, TypeScript, bundler, and test runner notes
|
|
139
|
+
- Native, shebang, Node compatibility, or package consumer risks
|
|
140
|
+
- Files changed
|
|
141
|
+
- Command intents run
|
|
142
|
+
- Skipped checks and reasons
|
|
143
|
+
- Remaining Bun risk
|
|
@@ -0,0 +1,262 @@
|
|
|
1
|
+
---
|
|
2
|
+
mustflow_doc: skill.docker-code-change
|
|
3
|
+
locale: en
|
|
4
|
+
canonical: true
|
|
5
|
+
revision: 1
|
|
6
|
+
lifecycle: mustflow-owned
|
|
7
|
+
authority: procedure
|
|
8
|
+
name: docker-code-change
|
|
9
|
+
description: Apply this skill when Dockerfiles, .dockerignore files, Docker Compose files, BuildKit or buildx behavior, container image metadata, image tags, container entrypoints, health checks, Docker-based CI workflows, image security scanning, SBOM or provenance settings, registry publishing, or container runtime validation are created or changed.
|
|
10
|
+
metadata:
|
|
11
|
+
mustflow_schema: "1"
|
|
12
|
+
mustflow_kind: procedure
|
|
13
|
+
pack_id: mustflow.core
|
|
14
|
+
skill_id: mustflow.core.docker-code-change
|
|
15
|
+
command_intents:
|
|
16
|
+
- changes_status
|
|
17
|
+
- changes_diff_summary
|
|
18
|
+
- lint
|
|
19
|
+
- build
|
|
20
|
+
- test_related
|
|
21
|
+
- test
|
|
22
|
+
- docs_validate_fast
|
|
23
|
+
- test_release
|
|
24
|
+
- mustflow_check
|
|
25
|
+
---
|
|
26
|
+
|
|
27
|
+
# Docker Code Change
|
|
28
|
+
|
|
29
|
+
<!-- mustflow-section: purpose -->
|
|
30
|
+
## Purpose
|
|
31
|
+
|
|
32
|
+
Prevent container image accidents by preserving reproducibility, secret safety, cache behavior,
|
|
33
|
+
runtime correctness, development and production separation, and supply-chain evidence.
|
|
34
|
+
|
|
35
|
+
This skill is not a Docker syntax guide. It is a safety procedure for changing Docker-based
|
|
36
|
+
application images and local container workflows without silently weakening build, runtime, CI,
|
|
37
|
+
or security contracts.
|
|
38
|
+
|
|
39
|
+
<!-- mustflow-section: use-when -->
|
|
40
|
+
## Use When
|
|
41
|
+
|
|
42
|
+
- `Dockerfile`, `Dockerfile.*`, `.dockerignore`, `compose.yaml`, `compose.yml`,
|
|
43
|
+
`docker-compose*.yml`, or Compose override files are created or changed.
|
|
44
|
+
- Base images, image tags, digest pinning, package-manager install layers, build contexts,
|
|
45
|
+
multi-stage boundaries, `ENTRYPOINT`, `CMD`, `USER`, `HEALTHCHECK`, `EXPOSE`, labels,
|
|
46
|
+
environment variables, or build arguments change.
|
|
47
|
+
- BuildKit, buildx, build targets, cache mounts, external cache, multi-platform image builds,
|
|
48
|
+
Docker-based CI workflows, image publish behavior, registry tags, SBOM, provenance,
|
|
49
|
+
signing, or image vulnerability scanning changes.
|
|
50
|
+
- Local development Compose services such as databases, Redis, queues, object stores,
|
|
51
|
+
mail capture, optional debug tools, profiles, volumes, networks, env files, init scripts,
|
|
52
|
+
or migration jobs change.
|
|
53
|
+
- A language-specific runtime skill mentions Docker base images, native dependency image
|
|
54
|
+
behavior, container deployment support, or Docker runtime declarations.
|
|
55
|
+
|
|
56
|
+
<!-- mustflow-section: do-not-use-when -->
|
|
57
|
+
## Do Not Use When
|
|
58
|
+
|
|
59
|
+
- The task only changes application code that happens to run inside an unchanged container;
|
|
60
|
+
use the matching language or framework skill.
|
|
61
|
+
- The task only changes generic environment variables, secrets, or deployment settings
|
|
62
|
+
outside Docker or Compose; use `config-env-change` or the narrower deployment skill.
|
|
63
|
+
- The task designs Kubernetes, ECS, Cloud Run, Nomad, service mesh, registry administration,
|
|
64
|
+
autoscaling, backup, ingress, TLS, or cloud platform resources beyond verifying that an
|
|
65
|
+
image is deployable.
|
|
66
|
+
- The task only addresses shell process execution or filesystem path handling outside
|
|
67
|
+
container files; use `process-execution-safety`, `file-path-cross-platform-change`, or
|
|
68
|
+
`cross-platform-filesystem-safety`.
|
|
69
|
+
|
|
70
|
+
<!-- mustflow-section: required-inputs -->
|
|
71
|
+
## Required Inputs
|
|
72
|
+
|
|
73
|
+
- Container surfaces: Dockerfiles, `.dockerignore`, Compose files, CI workflow files,
|
|
74
|
+
build scripts or command-contract entries, release workflow files, and registry metadata
|
|
75
|
+
touched by the change.
|
|
76
|
+
- Project classification: runtime-source app, compiled artifact app, JVM artifact app,
|
|
77
|
+
static frontend, multi-service app, or mixed image set, with language examples such as
|
|
78
|
+
Node, Bun, Python, PHP, Go, Rust, C++, and Java.
|
|
79
|
+
- Base image and platform signals: image names, tags, digests, OS family, libc expectations,
|
|
80
|
+
CPU architecture, native dependencies, required CA certificates, time zone, shell, package
|
|
81
|
+
manager, and runtime user needs.
|
|
82
|
+
- Build and cache signals: build context, `.dockerignore`, lockfiles, package-manager cache
|
|
83
|
+
paths, BuildKit mount needs, stage names, build targets, external cache ownership, and
|
|
84
|
+
CI event or branch conditions.
|
|
85
|
+
- Runtime contract: `USER`, file ownership, writable paths, `ENTRYPOINT`, `CMD`, signal
|
|
86
|
+
handling, health checks, ports, logs, config injection, read-only filesystem expectations,
|
|
87
|
+
volumes, and smoke-test path.
|
|
88
|
+
- Security and supply-chain contract: secrets, SSH keys, private registry tokens, Docker socket
|
|
89
|
+
access, privileged mode, host namespace or host path access, capabilities, security options,
|
|
90
|
+
vulnerability scan gate, SBOM, provenance, signing, and digest reporting.
|
|
91
|
+
- Configured command intents that can validate syntax, build output, tests, docs, release
|
|
92
|
+
packaging, and mustflow workflow alignment. Report missing Docker-specific verification
|
|
93
|
+
intents instead of inventing raw Docker commands.
|
|
94
|
+
|
|
95
|
+
<!-- mustflow-section: preconditions -->
|
|
96
|
+
## Preconditions
|
|
97
|
+
|
|
98
|
+
- Classify whether the change affects local development only, CI validation, release images,
|
|
99
|
+
registry publishing, or deployable runtime behavior before editing.
|
|
100
|
+
- Do not optimize a Dockerfile by blindly minimizing line count or image size. Preserve
|
|
101
|
+
reproducibility, secret safety, cache behavior, runtime correctness, and dev/prod separation
|
|
102
|
+
first.
|
|
103
|
+
- Treat Dockerfiles, Compose files, and Docker CI workflows as security-sensitive when they
|
|
104
|
+
can alter credentials, registry writes, host access, runtime privileges, or supply-chain
|
|
105
|
+
attestations.
|
|
106
|
+
- Do not assume Docker, buildx, Compose, Scout, Trivy, Grype, or registry credentials are
|
|
107
|
+
available unless the repository exposes a configured one-shot command intent or the user
|
|
108
|
+
explicitly accepts an unverified manual path.
|
|
109
|
+
|
|
110
|
+
<!-- mustflow-section: allowed-edits -->
|
|
111
|
+
## Allowed Edits
|
|
112
|
+
|
|
113
|
+
- Update Dockerfiles, `.dockerignore`, Compose files, container-related CI workflow snippets,
|
|
114
|
+
image metadata, package tests, docs examples, template metadata, and directly synchronized
|
|
115
|
+
skill routes required by the container contract.
|
|
116
|
+
- Add or tighten non-root runtime users, stage names, `.dockerignore` exclusions, cache-safe
|
|
117
|
+
copy order, BuildKit secret or cache requirements, health checks, labels, and Compose local
|
|
118
|
+
dependency wiring when the current project evidence supports the change.
|
|
119
|
+
- Add focused tests or assertions only when they encode the changed container, template,
|
|
120
|
+
package, or workflow contract.
|
|
121
|
+
- Do not add broad deployment platform design, registry administration, long-running server
|
|
122
|
+
instructions, raw publish commands, credential material, or command permission to a skill
|
|
123
|
+
document.
|
|
124
|
+
|
|
125
|
+
<!-- mustflow-section: procedure -->
|
|
126
|
+
## Procedure
|
|
127
|
+
|
|
128
|
+
1. Classify the changed surface: Dockerfile, `.dockerignore`, Compose, CI build workflow,
|
|
129
|
+
image publish workflow, image metadata, security scan, SBOM/provenance, or runtime smoke
|
|
130
|
+
path. If several surfaces changed, name the source of truth for each.
|
|
131
|
+
2. Classify the image shape before choosing structure:
|
|
132
|
+
- Runtime-source apps keep source plus production runtime dependencies.
|
|
133
|
+
- Compiled artifact apps should usually copy only the binary and required runtime files.
|
|
134
|
+
- JVM artifact apps should build with a JDK and run with a JRE or equivalent runtime image.
|
|
135
|
+
- Static frontends should copy only built assets into the serving image when applicable.
|
|
136
|
+
3. Choose base images deliberately. Prefer trusted versioned images over mutable `latest`.
|
|
137
|
+
Use Debian slim as a conservative default for native dependency compatibility; use Alpine
|
|
138
|
+
only after libc and native package behavior are verified; use distroless or `scratch` only
|
|
139
|
+
when CA certificates, time zone, passwd or non-root identity, shell absence, and debugging
|
|
140
|
+
tradeoffs are explicit.
|
|
141
|
+
4. Treat digest pinning as a reproducibility choice with an update obligation. If a production
|
|
142
|
+
sample pins a digest, also report the need for an update mechanism such as dependency update
|
|
143
|
+
automation, base-image rebuild checks, or a scanner policy.
|
|
144
|
+
5. Preserve build cache boundaries. Keep build context small, copy dependency manifests and
|
|
145
|
+
lockfiles before application source, avoid copying host dependency directories, and keep
|
|
146
|
+
package-manager caches out of final images. Do not move `COPY . .` above dependency install
|
|
147
|
+
layers unless the project has no cache-sensitive dependency step.
|
|
148
|
+
6. Check `.dockerignore` whenever build context changes. Exclude VCS metadata, local dependency
|
|
149
|
+
directories, virtual environments, build output, coverage, caches, local databases, `.env`,
|
|
150
|
+
credential files, keys, and other files not required by the build.
|
|
151
|
+
7. Use multi-stage boundaries only when they buy cache, artifact, security, or test-target value.
|
|
152
|
+
Name stages instead of relying on numeric indexes. Remove stages that merely rename the same
|
|
153
|
+
base without changing cache behavior, artifact flow, runtime base, or verification target.
|
|
154
|
+
8. Ensure final images contain only runtime requirements. Do not leave compilers, package managers,
|
|
155
|
+
test fixtures, source maps, caches, `git`, `curl`, shell tools, or dev dependencies in final
|
|
156
|
+
images unless the runtime contract explicitly requires them.
|
|
157
|
+
9. Handle secrets as a hard boundary. Do not put tokens, passwords, SSH keys, cloud credentials,
|
|
158
|
+
`.npmrc`, `.pypirc`, `.env`, or private registry credentials into `ARG`, `ENV`, labels,
|
|
159
|
+
image layers, build logs, copied files, or command history. Prefer BuildKit secret or SSH
|
|
160
|
+
mounts when a configured workflow supports them, and report missing secret-mount verification
|
|
161
|
+
when it does not.
|
|
162
|
+
10. Preserve runtime correctness. Verify non-root user intent, file ownership, writable paths,
|
|
163
|
+
entrypoint and command shape, PID 1 signal handling, exposed and published ports, logs to
|
|
164
|
+
stdout or stderr, health check command availability, required environment variables, and
|
|
165
|
+
read-only filesystem expectations.
|
|
166
|
+
11. Treat `USER` as a runtime proof obligation, not a text check. If the final image runs as
|
|
167
|
+
non-root, make sure copied files and runtime write paths are owned or writable by that user.
|
|
168
|
+
If that cannot be verified, report the missing run evidence.
|
|
169
|
+
12. Keep Compose scoped. Use Compose for local development, integration tests, and narrow
|
|
170
|
+
production-like checks. Do not turn Compose into a full orchestrator design for TLS,
|
|
171
|
+
autoscaling, backups, ingress, secret rotation, or platform rollout strategy.
|
|
172
|
+
13. For Compose dependencies, distinguish container start from service readiness. Prefer
|
|
173
|
+
health checks for databases and queues, app-level retry for runtime dependency loss, named
|
|
174
|
+
volumes for persistent local data, bind mounts for editable source, profiles for optional
|
|
175
|
+
tools, and one-shot migration services rather than hiding app migrations inside database
|
|
176
|
+
image entrypoints.
|
|
177
|
+
14. Review Compose trust and host access. Treat `privileged`, Docker socket mounts, host
|
|
178
|
+
networking, host PID or IPC namespaces, broad host-path mounts, root users, broad port
|
|
179
|
+
binding, unconfined security profiles, and missing resource limits as high-risk changes
|
|
180
|
+
requiring explicit justification.
|
|
181
|
+
15. For CI, separate test builds from publish builds. PR and fork events should not push images,
|
|
182
|
+
receive registry credentials, write production caches, sign artifacts, or use deployment
|
|
183
|
+
secrets. Release tags or protected default-branch jobs may publish only after the configured
|
|
184
|
+
verification path succeeds.
|
|
185
|
+
16. Keep cache ownership safe in CI. Do not let untrusted PRs overwrite default-branch cache
|
|
186
|
+
refs. Use branch- or event-scoped cache references when the workflow supports external cache.
|
|
187
|
+
Report cache poisoning risk when the workflow writes shared caches from untrusted code.
|
|
188
|
+
17. Keep image tags traceable. Use immutable commit or digest evidence for deployable artifacts.
|
|
189
|
+
Treat `latest` as a moving pointer, not a release identity. Release workflows should record
|
|
190
|
+
the pushed digest and update floating tags only from release or protected branch events.
|
|
191
|
+
18. For release images, require SBOM and provenance when the configured workflow supports them.
|
|
192
|
+
Report when local-only image loads cannot carry registry attestations and when final published
|
|
193
|
+
digests were not rechecked after push.
|
|
194
|
+
19. Choose verification through configured intents first. If Docker-specific syntax, build,
|
|
195
|
+
smoke, inspect, history, vulnerability scan, SBOM, provenance, multi-arch, or registry-pull
|
|
196
|
+
verification is needed but not configured, report the missing intent instead of running an
|
|
197
|
+
inferred command.
|
|
198
|
+
20. When reporting completion, separate source edits, image-build evidence, runtime evidence,
|
|
199
|
+
security scan evidence, supply-chain evidence, registry evidence, and skipped checks. Do not
|
|
200
|
+
claim a container image is production-ready from source inspection or a successful build alone.
|
|
201
|
+
|
|
202
|
+
<!-- mustflow-section: postconditions -->
|
|
203
|
+
## Postconditions
|
|
204
|
+
|
|
205
|
+
- The image shape, base image choice, cache order, stage boundaries, and build context are
|
|
206
|
+
deliberate and aligned with the language or runtime contract.
|
|
207
|
+
- Secrets are not introduced into Dockerfile instructions, Compose environment, image layers,
|
|
208
|
+
command history, logs, SBOM, or provenance metadata.
|
|
209
|
+
- Final runtime images avoid root execution and unnecessary build tools unless explicitly justified.
|
|
210
|
+
- Compose remains local or narrowly production-like, with host access and privileged settings
|
|
211
|
+
justified or rejected.
|
|
212
|
+
- CI image builds separate test, cache, publish, tag, SBOM, provenance, and registry credentials
|
|
213
|
+
according to event trust.
|
|
214
|
+
- Docker-specific verification evidence is recorded, or missing configured intents are reported.
|
|
215
|
+
|
|
216
|
+
<!-- mustflow-section: verification -->
|
|
217
|
+
## Verification
|
|
218
|
+
|
|
219
|
+
Use configured oneshot command intents when available:
|
|
220
|
+
|
|
221
|
+
- `lint`
|
|
222
|
+
- `build`
|
|
223
|
+
- `test_related`
|
|
224
|
+
- `test`
|
|
225
|
+
- `docs_validate_fast`
|
|
226
|
+
- `test_release`
|
|
227
|
+
- `mustflow_check`
|
|
228
|
+
|
|
229
|
+
Report missing Dockerfile lint, Compose config validation, buildx check, image build, container
|
|
230
|
+
start, health or smoke test, image inspect, history secret scan, vulnerability scan, SBOM,
|
|
231
|
+
provenance, multi-platform manifest, registry push, registry pull, or digest verification intents
|
|
232
|
+
when those surfaces change.
|
|
233
|
+
|
|
234
|
+
<!-- mustflow-section: failure-handling -->
|
|
235
|
+
## Failure Handling
|
|
236
|
+
|
|
237
|
+
- If a build succeeds but runtime start, health, smoke, or non-root write behavior is unverified,
|
|
238
|
+
report the image as built but not runtime-verified.
|
|
239
|
+
- If a secret appears in `ARG`, `ENV`, copied files, image history, logs, or attestation metadata,
|
|
240
|
+
remove the leak path before optimizing cache or image size.
|
|
241
|
+
- If Alpine, distroless, or `scratch` breaks native dependencies, CA certificates, time zones,
|
|
242
|
+
shell availability, or non-root identity, restore a compatible runtime base or report the
|
|
243
|
+
missing runtime requirement.
|
|
244
|
+
- If Compose uses Docker socket, privileged mode, host namespaces, broad host mounts, root users,
|
|
245
|
+
or broad port exposure without explicit justification, treat the change as unsafe.
|
|
246
|
+
- If CI publish behavior is triggered from untrusted events, forks, or ordinary PRs, fail closed
|
|
247
|
+
by disabling push or credentials for that path and report the publish boundary.
|
|
248
|
+
- If Docker-specific tools or registries are unavailable under the command contract, do not invent
|
|
249
|
+
manual commands; report the missing verification intent and remaining risk.
|
|
250
|
+
|
|
251
|
+
<!-- mustflow-section: output-format -->
|
|
252
|
+
## Output Format
|
|
253
|
+
|
|
254
|
+
- Docker surface classification
|
|
255
|
+
- Image shape, base image, cache, and stage decisions
|
|
256
|
+
- `.dockerignore`, secret, user, entrypoint, health, port, and runtime notes
|
|
257
|
+
- Compose trust, volume, network, env, readiness, and migration notes
|
|
258
|
+
- CI cache, tag, publish, SBOM, provenance, registry, and event-trust notes
|
|
259
|
+
- Files changed
|
|
260
|
+
- Command intents run
|
|
261
|
+
- Skipped Docker-specific checks and reasons
|
|
262
|
+
- Remaining Docker risk
|
|
@@ -0,0 +1,145 @@
|
|
|
1
|
+
---
|
|
2
|
+
mustflow_doc: skill.node-code-change
|
|
3
|
+
locale: en
|
|
4
|
+
canonical: true
|
|
5
|
+
revision: 1
|
|
6
|
+
lifecycle: mustflow-owned
|
|
7
|
+
authority: procedure
|
|
8
|
+
name: node-code-change
|
|
9
|
+
description: Apply this skill when Node.js runtime code, package manager ownership, module format, package entry metadata, native dependencies, Node test runner behavior, TypeScript execution mode, or deployment runtime support is created or changed.
|
|
10
|
+
metadata:
|
|
11
|
+
mustflow_schema: "1"
|
|
12
|
+
mustflow_kind: procedure
|
|
13
|
+
pack_id: mustflow.core
|
|
14
|
+
skill_id: mustflow.core.node-code-change
|
|
15
|
+
command_intents:
|
|
16
|
+
- changes_status
|
|
17
|
+
- changes_diff_summary
|
|
18
|
+
- lint
|
|
19
|
+
- build
|
|
20
|
+
- test_related
|
|
21
|
+
- test
|
|
22
|
+
- docs_validate_fast
|
|
23
|
+
- test_release
|
|
24
|
+
- mustflow_check
|
|
25
|
+
---
|
|
26
|
+
|
|
27
|
+
# Node Code Change
|
|
28
|
+
|
|
29
|
+
<!-- mustflow-section: purpose -->
|
|
30
|
+
## Purpose
|
|
31
|
+
|
|
32
|
+
Preserve the actual Node.js runtime, module, package manager, TypeScript execution, test runner, package entry, native dependency, and deployment boundaries.
|
|
33
|
+
|
|
34
|
+
<!-- mustflow-section: use-when -->
|
|
35
|
+
## Use When
|
|
36
|
+
|
|
37
|
+
- Node.js runtime code, `node:*` APIs, `process`, `Buffer`, streams, workers, child processes, native addons, Node permission flags, Node test runner behavior, package entry metadata, or deployment runtime support changes.
|
|
38
|
+
- `package.json` Node fields change, including `engines.node`, `devEngines`, `packageManager`, `type`, `main`, `exports`, `imports`, `types`, `typesVersions`, `files`, `bin`, `sideEffects`, or `workspaces`.
|
|
39
|
+
- Node version signals, CI Node setup, Docker Node base images, serverless Node runtime settings, Corepack usage, npm, pnpm, Yarn, or lockfile ownership changes.
|
|
40
|
+
- The task proposes native Node TypeScript execution, ESM/CJS conversion, conditional exports, package manager migration, or Node built-in test runner migration.
|
|
41
|
+
|
|
42
|
+
<!-- mustflow-section: do-not-use-when -->
|
|
43
|
+
## Do Not Use When
|
|
44
|
+
|
|
45
|
+
- The task only changes TypeScript type modeling, validators, declarations, or `.ts` source without Node runtime or package entry impact; use `typescript-code-change`.
|
|
46
|
+
- The task only changes plain JavaScript without Node-specific runtime, package, or deployment behavior; use `javascript-code-change`.
|
|
47
|
+
- Bun owns the runtime, package manager, test runner, or bundler behavior being changed; use `bun-code-change`.
|
|
48
|
+
- A narrower framework skill owns the changed route or handler surface, unless Node runtime, package, or deployment behavior is also affected.
|
|
49
|
+
|
|
50
|
+
<!-- mustflow-section: required-inputs -->
|
|
51
|
+
## Required Inputs
|
|
52
|
+
|
|
53
|
+
- Node version signals: `.nvmrc`, `.node-version`, `.tool-versions`, Volta or mise/asdf config, `package.json#engines.node`, `package.json#devEngines`, CI Node matrix, Docker `FROM node:*`, and deployment runtime config.
|
|
54
|
+
- Package ownership signals: `package.json#packageManager`, npm, pnpm, Yarn, Bun, or vlt lockfiles, workspace config, `.npmrc`, `.yarnrc.yml`, Corepack usage, CI install commands, and Docker install commands.
|
|
55
|
+
- Module and package metadata: nearest `package.json#type`, file extensions, `main`, `module`, `exports`, `imports`, `types`, `typings`, `typesVersions`, `files`, `bin`, `sideEffects`, and documented import paths.
|
|
56
|
+
- TypeScript and loader signals: `tsconfig*.json`, `tsx`, `ts-node`, SWC, Babel, Vite, tsup, esbuild, Node native type stripping, path aliases, declaration output, and test or build transforms.
|
|
57
|
+
- Test, native, and deployment signals: package scripts, test runner config, `node:test` usage, native dependency indicators such as `.node`, `binding.gyp`, `node-gyp`, lifecycle scripts, optional dependencies, serverless or edge config, and command contract entries.
|
|
58
|
+
|
|
59
|
+
<!-- mustflow-section: preconditions -->
|
|
60
|
+
## Preconditions
|
|
61
|
+
|
|
62
|
+
- Determine the effective Node runtime before using newer syntax, APIs, or flags.
|
|
63
|
+
- Determine package manager ownership before editing dependencies or lockfiles.
|
|
64
|
+
- Determine Node's actual module loading path before changing imports, file extensions, or package entry metadata.
|
|
65
|
+
- Treat package entry, engine, and lockfile changes as public contract or release-sensitive changes unless proven internal.
|
|
66
|
+
|
|
67
|
+
<!-- mustflow-section: allowed-edits -->
|
|
68
|
+
## Allowed Edits
|
|
69
|
+
|
|
70
|
+
- Keep runtime-specific Node APIs in Node-owned files or adapters.
|
|
71
|
+
- Keep package manager changes aligned with the owner already used by CI, Docker, and lockfiles.
|
|
72
|
+
- Keep ESM, CJS, and dual package boundaries explicit and synchronized with declarations, tests, docs examples, and consumer entrypoints.
|
|
73
|
+
- Preserve existing TypeScript build, typecheck, declaration, and loader pipelines unless the task explicitly asks to replace them.
|
|
74
|
+
- Add or update focused tests only when they protect the changed runtime, package, module, native, or deployment contract.
|
|
75
|
+
|
|
76
|
+
<!-- mustflow-section: procedure -->
|
|
77
|
+
## Procedure
|
|
78
|
+
|
|
79
|
+
1. Read runtime version signals before editing. Treat deployment runtime as the hard constraint, CI runtime as the verified constraint, `engines.node` as the compatibility contract, and local version files as developer hints. If these conflict, report the conflict before introducing APIs or syntax that depend on one side.
|
|
80
|
+
2. Do not assume Node Current. Use Current-only APIs only when local tooling, CI, Docker, deployment, package metadata, and intended consumers all prove support for that Current major. For production applications, prefer Active LTS or Maintenance LTS when the project does not declare otherwise.
|
|
81
|
+
3. Determine package manager ownership from `packageManager`, lockfiles, workspace config, CI, and Docker. If `packageManager` and lockfiles disagree, or multiple lockfiles exist, do not rewrite dependencies until the owner and migration intent are clear.
|
|
82
|
+
4. Keep package manager semantics distinct:
|
|
83
|
+
- npm dependency changes update `package.json` and npm lockfiles; clean CI installs use npm's clean-install mode.
|
|
84
|
+
- pnpm workspaces and frozen lockfile behavior can affect every workspace even when one package changed.
|
|
85
|
+
- Yarn PnP, Zero-Install, and immutable installs can make `node_modules` assumptions wrong.
|
|
86
|
+
- Corepack availability depends on the Node/runtime environment; do not assume it exists in every Node version, image, or CI runner.
|
|
87
|
+
5. Determine Node module loading from Node rules, not preference or `tsconfig` alone. `.mjs` and `.mts` are ESM, `.cjs` and `.cts` are CommonJS, and `.js` or `.ts` follows the nearest package `type` after the project's loader/build path is considered.
|
|
88
|
+
6. Treat `type`, `main`, `exports`, `imports`, file extensions, and conditional export changes as package entry contract changes. Adding `exports` can block deep imports and should be classified as compatibility-sensitive unless all previously supported paths remain exported or the release is intentionally breaking.
|
|
89
|
+
7. For conditional exports, keep condition order deliberate, include a `default` fallback when multi-runtime or bundler consumers are intended, and avoid splitting `import` and `require` into separate stateful implementations unless dual package hazards are tested.
|
|
90
|
+
8. For `imports`, use `#` aliases only for package-internal paths, and keep TypeScript paths, bundler aliases, test runner aliases, and declaration output aligned.
|
|
91
|
+
9. For JSON imports, `require(esm)`, top-level await, `.mts`, `.cts`, `.d.mts`, and `.d.cts`, verify the minimum Node version, TypeScript module resolution, generated output, and consumer path before changing code.
|
|
92
|
+
10. Do not replace an existing TypeScript pipeline with native Node TypeScript execution unless the task explicitly asks for that migration. Node native TypeScript execution is limited type stripping; it does not typecheck, read `tsconfig`, resolve path aliases, emit declarations, downlevel syntax, transform decorators or enums, or support TSX as a full build pipeline.
|
|
93
|
+
11. If native Node TypeScript execution is intentionally used, keep syntax erasable-only, use `import type` for type-only imports, avoid runtime TypeScript features that require transforms, and keep the configured typecheck/build pipeline for application and library code.
|
|
94
|
+
12. Detect the actual test runner from scripts, config files, dependencies, and CI. Do not migrate Jest, Vitest, Playwright, or another runner to `node:test` just because Node has a built-in runner. Watch, coverage, mock, snapshot, worker, and cleanup behavior are runner-specific.
|
|
95
|
+
13. Treat watch mode and snapshot update modes as development or review actions, not final verification. Use the configured oneshot intents and report when no configured runner-specific intent exists.
|
|
96
|
+
14. Before using Node APIs in deployment code, classify the target as Node server, Docker, serverless Node, edge runtime, static build, or multi-runtime package. Edge runtimes are not full Node.js runtimes.
|
|
97
|
+
15. Inspect native and install-sensitive dependencies when package metadata or runtime imports touch `.node`, `binding.gyp`, `node-gyp`, `preinstall`, `install`, `postinstall`, `prepare`, optional dependencies, peer dependencies, OS, CPU, libc, or Node ABI boundaries.
|
|
98
|
+
16. Treat optional dependencies and optional peers as absent until code handles absence. Do not require optional packages directly without fallback or error handling that matches the existing project pattern.
|
|
99
|
+
17. Treat the Node permission model as a trusted-code seatbelt, not a sandbox for untrusted code. If permission flags are introduced or changed, map required filesystem, network, child process, worker, native addon, WASI, inspector, and temporary directory access explicitly.
|
|
100
|
+
18. Choose configured verification intents that cover lint, build, tests, package metadata, release-sensitive package output, docs examples, and mustflow contract checks when available. Report missing consumer fixture, ESM, CJS, TypeScript consumer, native dependency, deployment, or permission verification.
|
|
101
|
+
|
|
102
|
+
<!-- mustflow-section: postconditions -->
|
|
103
|
+
## Postconditions
|
|
104
|
+
|
|
105
|
+
- Effective Node runtime and package manager ownership are known or explicitly reported as conflicting.
|
|
106
|
+
- Module and package entry changes are synchronized with declarations, tests, docs examples, and consumer surfaces when relevant.
|
|
107
|
+
- Native TypeScript execution is not mistaken for typecheck, declaration emit, or a full build pipeline.
|
|
108
|
+
- Node-only APIs do not leak into browser, edge, Bun, or shared package surfaces unintentionally.
|
|
109
|
+
- Native dependency, lifecycle, optional dependency, and permission-model risks are handled or reported.
|
|
110
|
+
|
|
111
|
+
<!-- mustflow-section: verification -->
|
|
112
|
+
## Verification
|
|
113
|
+
|
|
114
|
+
Use configured oneshot command intents when available:
|
|
115
|
+
|
|
116
|
+
- `lint`
|
|
117
|
+
- `build`
|
|
118
|
+
- `test_related`
|
|
119
|
+
- `test`
|
|
120
|
+
- `docs_validate_fast`
|
|
121
|
+
- `test_release`
|
|
122
|
+
- `mustflow_check`
|
|
123
|
+
|
|
124
|
+
Report missing ESM/CJS consumer, declaration output, package artifact, frozen install, native dependency, deployment runtime, permission-model, or runner-specific verification intents when those surfaces change.
|
|
125
|
+
|
|
126
|
+
<!-- mustflow-section: failure-handling -->
|
|
127
|
+
## Failure Handling
|
|
128
|
+
|
|
129
|
+
- If runtime signals conflict, do not resolve the conflict by assuming the newest Node version.
|
|
130
|
+
- If package manager ownership conflicts, do not add, remove, or migrate dependencies until the owner is clear.
|
|
131
|
+
- If a package entry change blocks a documented or previously supported import path, restore compatibility or report the breaking-change requirement.
|
|
132
|
+
- If native Node TypeScript execution fails, repair the build/loader boundary instead of weakening typecheck or deleting the TypeScript pipeline.
|
|
133
|
+
- If native dependency installation or optional dependency behavior is unclear, classify the change as release-sensitive and report the missing install or runtime evidence.
|
|
134
|
+
|
|
135
|
+
<!-- mustflow-section: output-format -->
|
|
136
|
+
## Output Format
|
|
137
|
+
|
|
138
|
+
- Runtime and package manager decision
|
|
139
|
+
- Module and package entry notes
|
|
140
|
+
- TypeScript execution and test runner notes
|
|
141
|
+
- Native, lifecycle, deployment, or permission risks
|
|
142
|
+
- Files changed
|
|
143
|
+
- Command intents run
|
|
144
|
+
- Skipped checks and reasons
|
|
145
|
+
- Remaining Node.js risk
|
|
@@ -120,6 +120,24 @@ route_type = "primary"
|
|
|
120
120
|
priority = 85
|
|
121
121
|
applies_to_reasons = ["code_change", "public_api_change", "test_change", "package_metadata_change"]
|
|
122
122
|
|
|
123
|
+
[routes."node-code-change"]
|
|
124
|
+
category = "general_code"
|
|
125
|
+
route_type = "primary"
|
|
126
|
+
priority = 85
|
|
127
|
+
applies_to_reasons = ["code_change", "public_api_change", "test_change", "package_metadata_change"]
|
|
128
|
+
|
|
129
|
+
[routes."bun-code-change"]
|
|
130
|
+
category = "general_code"
|
|
131
|
+
route_type = "primary"
|
|
132
|
+
priority = 85
|
|
133
|
+
applies_to_reasons = ["code_change", "public_api_change", "test_change", "package_metadata_change"]
|
|
134
|
+
|
|
135
|
+
[routes."docker-code-change"]
|
|
136
|
+
category = "general_code"
|
|
137
|
+
route_type = "primary"
|
|
138
|
+
priority = 85
|
|
139
|
+
applies_to_reasons = ["code_change", "public_api_change", "test_change", "security_change", "package_metadata_change", "release_risk"]
|
|
140
|
+
|
|
123
141
|
[routes."api-contract-change"]
|
|
124
142
|
category = "general_code"
|
|
125
143
|
route_type = "primary"
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
id = "default"
|
|
2
2
|
name = "default"
|
|
3
|
-
version = "2.
|
|
3
|
+
version = "2.27.0"
|
|
4
4
|
description = "Minimal workflow for LLM agents to read, edit, and verify their work in a repository."
|
|
5
5
|
common_root = "common"
|
|
6
6
|
locales_root = "locales"
|
|
@@ -21,15 +21,18 @@ creates = [
|
|
|
21
21
|
".mustflow/skills/codebase-orientation/SKILL.md",
|
|
22
22
|
".mustflow/skills/clarifying-question-gate/SKILL.md",
|
|
23
23
|
".mustflow/skills/astro-code-change/SKILL.md",
|
|
24
|
+
".mustflow/skills/bun-code-change/SKILL.md",
|
|
24
25
|
".mustflow/skills/css-code-change/SKILL.md",
|
|
25
26
|
".mustflow/skills/cpp-code-change/SKILL.md",
|
|
26
27
|
".mustflow/skills/dart-code-change/SKILL.md",
|
|
28
|
+
".mustflow/skills/docker-code-change/SKILL.md",
|
|
27
29
|
".mustflow/skills/elysia-code-change/SKILL.md",
|
|
28
30
|
".mustflow/skills/flutter-code-change/SKILL.md",
|
|
29
31
|
".mustflow/skills/go-code-change/SKILL.md",
|
|
30
32
|
".mustflow/skills/hono-code-change/SKILL.md",
|
|
31
33
|
".mustflow/skills/html-code-change/SKILL.md",
|
|
32
34
|
".mustflow/skills/javascript-code-change/SKILL.md",
|
|
35
|
+
".mustflow/skills/node-code-change/SKILL.md",
|
|
33
36
|
".mustflow/skills/python-code-change/SKILL.md",
|
|
34
37
|
".mustflow/skills/rust-code-change/SKILL.md",
|
|
35
38
|
".mustflow/skills/svelte-code-change/SKILL.md",
|
|
@@ -129,15 +132,18 @@ minimal = [
|
|
|
129
132
|
"codebase-orientation",
|
|
130
133
|
"clarifying-question-gate",
|
|
131
134
|
"astro-code-change",
|
|
135
|
+
"bun-code-change",
|
|
132
136
|
"css-code-change",
|
|
133
137
|
"cpp-code-change",
|
|
134
138
|
"dart-code-change",
|
|
139
|
+
"docker-code-change",
|
|
135
140
|
"elysia-code-change",
|
|
136
141
|
"flutter-code-change",
|
|
137
142
|
"go-code-change",
|
|
138
143
|
"hono-code-change",
|
|
139
144
|
"html-code-change",
|
|
140
145
|
"javascript-code-change",
|
|
146
|
+
"node-code-change",
|
|
141
147
|
"python-code-change",
|
|
142
148
|
"rust-code-change",
|
|
143
149
|
"svelte-code-change",
|
|
@@ -182,15 +188,18 @@ patterns = [
|
|
|
182
188
|
"codebase-orientation",
|
|
183
189
|
"clarifying-question-gate",
|
|
184
190
|
"astro-code-change",
|
|
191
|
+
"bun-code-change",
|
|
185
192
|
"css-code-change",
|
|
186
193
|
"cpp-code-change",
|
|
187
194
|
"dart-code-change",
|
|
195
|
+
"docker-code-change",
|
|
188
196
|
"elysia-code-change",
|
|
189
197
|
"flutter-code-change",
|
|
190
198
|
"go-code-change",
|
|
191
199
|
"hono-code-change",
|
|
192
200
|
"html-code-change",
|
|
193
201
|
"javascript-code-change",
|
|
202
|
+
"node-code-change",
|
|
194
203
|
"python-code-change",
|
|
195
204
|
"rust-code-change",
|
|
196
205
|
"svelte-code-change",
|
|
@@ -246,15 +255,18 @@ oss = [
|
|
|
246
255
|
"codebase-orientation",
|
|
247
256
|
"clarifying-question-gate",
|
|
248
257
|
"astro-code-change",
|
|
258
|
+
"bun-code-change",
|
|
249
259
|
"css-code-change",
|
|
250
260
|
"cpp-code-change",
|
|
251
261
|
"dart-code-change",
|
|
262
|
+
"docker-code-change",
|
|
252
263
|
"elysia-code-change",
|
|
253
264
|
"flutter-code-change",
|
|
254
265
|
"go-code-change",
|
|
255
266
|
"hono-code-change",
|
|
256
267
|
"html-code-change",
|
|
257
268
|
"javascript-code-change",
|
|
269
|
+
"node-code-change",
|
|
258
270
|
"python-code-change",
|
|
259
271
|
"rust-code-change",
|
|
260
272
|
"svelte-code-change",
|
|
@@ -323,15 +335,18 @@ team = [
|
|
|
323
335
|
"codebase-orientation",
|
|
324
336
|
"clarifying-question-gate",
|
|
325
337
|
"astro-code-change",
|
|
338
|
+
"bun-code-change",
|
|
326
339
|
"css-code-change",
|
|
327
340
|
"cpp-code-change",
|
|
328
341
|
"dart-code-change",
|
|
342
|
+
"docker-code-change",
|
|
329
343
|
"elysia-code-change",
|
|
330
344
|
"flutter-code-change",
|
|
331
345
|
"go-code-change",
|
|
332
346
|
"hono-code-change",
|
|
333
347
|
"html-code-change",
|
|
334
348
|
"javascript-code-change",
|
|
349
|
+
"node-code-change",
|
|
335
350
|
"python-code-change",
|
|
336
351
|
"rust-code-change",
|
|
337
352
|
"svelte-code-change",
|
|
@@ -388,15 +403,18 @@ product = [
|
|
|
388
403
|
"codebase-orientation",
|
|
389
404
|
"clarifying-question-gate",
|
|
390
405
|
"astro-code-change",
|
|
406
|
+
"bun-code-change",
|
|
391
407
|
"css-code-change",
|
|
392
408
|
"cpp-code-change",
|
|
393
409
|
"dart-code-change",
|
|
410
|
+
"docker-code-change",
|
|
394
411
|
"elysia-code-change",
|
|
395
412
|
"flutter-code-change",
|
|
396
413
|
"go-code-change",
|
|
397
414
|
"hono-code-change",
|
|
398
415
|
"html-code-change",
|
|
399
416
|
"javascript-code-change",
|
|
417
|
+
"node-code-change",
|
|
400
418
|
"python-code-change",
|
|
401
419
|
"rust-code-change",
|
|
402
420
|
"svelte-code-change",
|
|
@@ -458,15 +476,18 @@ library = [
|
|
|
458
476
|
"codebase-orientation",
|
|
459
477
|
"clarifying-question-gate",
|
|
460
478
|
"astro-code-change",
|
|
479
|
+
"bun-code-change",
|
|
461
480
|
"css-code-change",
|
|
462
481
|
"cpp-code-change",
|
|
463
482
|
"dart-code-change",
|
|
483
|
+
"docker-code-change",
|
|
464
484
|
"elysia-code-change",
|
|
465
485
|
"flutter-code-change",
|
|
466
486
|
"go-code-change",
|
|
467
487
|
"hono-code-change",
|
|
468
488
|
"html-code-change",
|
|
469
489
|
"javascript-code-change",
|
|
490
|
+
"node-code-change",
|
|
470
491
|
"python-code-change",
|
|
471
492
|
"rust-code-change",
|
|
472
493
|
"svelte-code-change",
|