@theholocron/cli 4.10.3 → 4.11.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +18 -1
- package/dist/cli.mjs +8 -4
- package/dist/cli.mjs.map +1 -1
- package/package.json +5 -5
package/README.md
CHANGED
|
@@ -133,6 +133,21 @@ Writes `"holocron": "<holocronScript ?? 'holocron'>"` plus one
|
|
|
133
133
|
`"<task>": "holocron run <task>"` per runnable task. `syncScripts: false`
|
|
134
134
|
opts out entirely.
|
|
135
135
|
|
|
136
|
+
### `holocron run`
|
|
137
|
+
|
|
138
|
+
```bash
|
|
139
|
+
holocron run <task> [job] [--required] [--filter <pkg>] [--dry-run] [-- <passthrough>]
|
|
140
|
+
```
|
|
141
|
+
|
|
142
|
+
Runs one task locally — resolving turbo vs the package manager vs the tool
|
|
143
|
+
itself. A `job` argument targets a sub-job of tasks that have them: `holocron
|
|
144
|
+
run audit performance` runs Lighthouse CI, `holocron run audit knip` runs Knip,
|
|
145
|
+
`holocron run audit` (no job) runs every audit sub-job in declared order. A
|
|
146
|
+
sub-job whose tool isn't installed, or that has no local equivalent
|
|
147
|
+
(`bundle-size`), is skipped with a note — `--required` makes that a failure. For
|
|
148
|
+
a task with no sub-jobs the `job` slot is the first passthrough arg
|
|
149
|
+
(`holocron run build src/`).
|
|
150
|
+
|
|
136
151
|
### `holocron ci`
|
|
137
152
|
|
|
138
153
|
```bash
|
|
@@ -146,7 +161,9 @@ first failure — the "will my PR be green?" pre-flight, and what the
|
|
|
146
161
|
`--all` forces the full set; `--filter` is a `turbo --filter=` passthrough.
|
|
147
162
|
Order comes from the `CI_ORDER` constant in `@theholocron/astromech`
|
|
148
163
|
(`typecheck → lint → test → build → …`). Tasks with no local equivalent
|
|
149
|
-
(`
|
|
164
|
+
(`codeql`, `deploy`) are reported as enforced-in-CI, never failures; `audit`
|
|
165
|
+
expands into its sub-jobs (each under its own `audit / …` check context)
|
|
166
|
+
unless the repo ships its own `"audit"` script.
|
|
150
167
|
|
|
151
168
|
### Lint parity
|
|
152
169
|
|
package/dist/cli.mjs
CHANGED
|
@@ -6935,10 +6935,13 @@ try {
|
|
|
6935
6935
|
},
|
|
6936
6936
|
...argv.steps && argv.steps.length > 0 ? { steps: argv.steps } : {}
|
|
6937
6937
|
})).summary.fail > 0) process.exitCode = 1;
|
|
6938
|
-
}).command("run <task> [passthrough..]", "Run a task locally (test, typecheck, lint, build) — figures out turbo / the tool / the package manager", (y) => y.positional("task", {
|
|
6938
|
+
}).command("run <task> [job] [passthrough..]", "Run a task locally (test, typecheck, lint, build, audit) — figures out turbo / the tool / the package manager", (y) => y.positional("task", {
|
|
6939
6939
|
type: "string",
|
|
6940
6940
|
demandOption: true,
|
|
6941
|
-
describe: "Task name (test, typecheck, lint, build). See `holocron run --help`."
|
|
6941
|
+
describe: "Task name (test, typecheck, lint, build, audit). See `holocron run --help`."
|
|
6942
|
+
}).positional("job", {
|
|
6943
|
+
type: "string",
|
|
6944
|
+
describe: "Sub-job within the task (e.g. `holocron run audit performance`). Omit to run every job. Only `audit` has jobs today."
|
|
6942
6945
|
}).positional("passthrough", {
|
|
6943
6946
|
type: "string",
|
|
6944
6947
|
array: true,
|
|
@@ -6958,6 +6961,7 @@ try {
|
|
|
6958
6961
|
logger,
|
|
6959
6962
|
config
|
|
6960
6963
|
}).run(argv.task, {
|
|
6964
|
+
...argv.job !== void 0 ? { job: argv.job } : {},
|
|
6961
6965
|
passthrough: argv.passthrough ?? [],
|
|
6962
6966
|
dryRun: argv.dryRun,
|
|
6963
6967
|
required: argv.required,
|
|
@@ -7376,8 +7380,8 @@ try {
|
|
|
7376
7380
|
let extra = [];
|
|
7377
7381
|
try {
|
|
7378
7382
|
const raw = readFileSync(join(argv.cwd, "holocron.config.json"), "utf8");
|
|
7379
|
-
const
|
|
7380
|
-
if (Array.isArray(
|
|
7383
|
+
const extraRaw = JSON.parse(raw).upgrade?.node?.extra;
|
|
7384
|
+
if (Array.isArray(extraRaw)) extra = extraRaw;
|
|
7381
7385
|
} catch {}
|
|
7382
7386
|
const report = await runUpgradeNode({
|
|
7383
7387
|
to: argv.to,
|