@theholocron/cli 5.0.0-alpha.13 → 5.0.0-alpha.134
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 +197 -50
- package/dist/cli.mjs +2218 -889
- package/dist/cli.mjs.map +1 -1
- package/dist/index.d.mts +245 -22
- package/dist/index.mjs +271 -6
- package/dist/plugin/capabilities.d.mts +153 -22
- package/dist/plugin/capabilities.mjs +1 -0
- package/package.json +17 -11
package/README.md
CHANGED
|
@@ -17,17 +17,25 @@ holocron --help
|
|
|
17
17
|
## Interactive mode
|
|
18
18
|
|
|
19
19
|
Run `holocron` with no command, a parent command with no subcommand
|
|
20
|
-
(`holocron auth`, `holocron
|
|
21
|
-
missing a required positional (`holocron deploy`, `holocron
|
|
22
|
-
you get a prompt instead of a `--help` dead end
|
|
23
|
-
|
|
24
|
-
|
|
20
|
+
(`holocron auth`, `holocron repo`, `holocron repo upgrade`, …), or a leaf command
|
|
21
|
+
missing a required positional (`holocron deploy`, `holocron secrets set`), and
|
|
22
|
+
you get a prompt instead of a `--help` dead end.
|
|
23
|
+
|
|
24
|
+
The menu mirrors the command tree: each level shows only the next word, and a
|
|
25
|
+
group (marked `›`) opens its own submenu, as deep as the commands nest. Nothing
|
|
26
|
+
is shown as a `<command> <subcommand>` path — `config show` is `config ›` then
|
|
27
|
+
`show`. Every submenu has a `← back` item, and a command that is also a group
|
|
28
|
+
(`repo sync`, `deploy`) has a `(run it)` item at the top of its submenu. Typing
|
|
29
|
+
searches the whole tree — `upgrade` at the top finds the `repo` group — with
|
|
30
|
+
name matches ranked above description matches.
|
|
31
|
+
|
|
32
|
+
```console
|
|
25
33
|
$ holocron
|
|
26
|
-
? What would you like to do? ›
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
?
|
|
34
|
+
? What would you like to do? › repo
|
|
35
|
+
❯ repo ›
|
|
36
|
+
? repo — choose a subcommand: › upgrade
|
|
37
|
+
? repo upgrade — choose a subcommand: › node
|
|
38
|
+
? Target Node.js major version: › 24
|
|
31
39
|
```
|
|
32
40
|
|
|
33
41
|
The picked command spawns as a normal `holocron <command> …` invocation —
|
|
@@ -35,15 +43,30 @@ The picked command spawns as a normal `holocron <command> …` invocation —
|
|
|
35
43
|
through. A non-interactive shell (CI, a script, a pipe) gets the old
|
|
36
44
|
hard-failure message instead of hanging on a prompt.
|
|
37
45
|
|
|
46
|
+
For a command whose handler honours `--dry-run` (most of them — everything
|
|
47
|
+
except `auth *` and `config show`), the menu always previews it first — a
|
|
48
|
+
dry run doesn't mutate anything, so there's nothing to ask permission for —
|
|
49
|
+
then asks the one real decision:
|
|
50
|
+
|
|
51
|
+
```console
|
|
52
|
+
...dry-run output...
|
|
53
|
+
? Dry run complete — proceed with the real run? › yes
|
|
54
|
+
```
|
|
55
|
+
|
|
56
|
+
A preview that reports nothing would actually change (e.g. `clone` finding
|
|
57
|
+
every repo already cloned) skips that question too — there'd be nothing for
|
|
58
|
+
the real run to do either. `--skip-dry-run` opts out of the preview
|
|
59
|
+
entirely, straight to the real run, for when you already know what you want.
|
|
60
|
+
|
|
38
61
|
## Execution contexts
|
|
39
62
|
|
|
40
63
|
Every command is tagged with how much of a repo it needs:
|
|
41
64
|
|
|
42
|
-
| Context | Needs | Examples
|
|
43
|
-
| ------------ | -------------------------------------------------------- |
|
|
44
|
-
| `global` |
|
|
45
|
-
| `repo-aware` | `./holocron.config
|
|
46
|
-
| `workspace` | the `@theholocron/holocron-plugin-*` packages resolvable | `doctor`, `setup`, `sync`, `secrets
|
|
65
|
+
| Context | Needs | Examples |
|
|
66
|
+
| ------------ | -------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------- |
|
|
67
|
+
| `global` | the CLI binary alone | `version`, `clone`, `new repo` / `plugin`, `repo upgrade …`, `auth set` / `check`, `package …`, `run lint commit-msg`, `skills …` |
|
|
68
|
+
| `repo-aware` | `./holocron.config`, walking up from cwd, no plugins | `run`, `run ci`, `config show`, `repo sync readme`, `deploy on-release` |
|
|
69
|
+
| `workspace` | the `@theholocron/holocron-plugin-*` packages resolvable | `doctor`, `repo setup`, `repo sync`, `secrets …`, `deploy`, `sync github` |
|
|
47
70
|
|
|
48
71
|
A `workspace` command run from a bare global install (no plugins next to the
|
|
49
72
|
CLI) fails with one actionable line — install the plugins as devDependencies or
|
|
@@ -51,6 +74,21 @@ use `pnpm exec holocron <cmd>`. `auth check` degrades to "token present,
|
|
|
51
74
|
verification skipped" instead. `holocron --help` prints the grouping; see
|
|
52
75
|
[Execution Contexts](https://theholocron.github.io/holocron/execution-contexts).
|
|
53
76
|
|
|
77
|
+
### Viewing the resolved config
|
|
78
|
+
|
|
79
|
+
`holocron config show` prints the resolved config. On a TTY it opens a foldable
|
|
80
|
+
tree by default; piped or redirected, it always emits plain, valid JSON
|
|
81
|
+
(`holocron config show | jq`).
|
|
82
|
+
|
|
83
|
+
```console
|
|
84
|
+
holocron config show # TTY: foldable tree (↑↓ move, →/⏎ expand, ← collapse, E/C all, q quit)
|
|
85
|
+
holocron config show --depth 2 # static coloured tree, anything nested deeper than 2 levels collapsed
|
|
86
|
+
holocron config show --no-interactive # static coloured tree, fully expanded
|
|
87
|
+
```
|
|
88
|
+
|
|
89
|
+
Passing `--interactive` explicitly needs a TTY on stdin and stdout and fails
|
|
90
|
+
with a one-line message otherwise; the default falls back to static output. It has no extra dependencies — nothing to install.
|
|
91
|
+
|
|
54
92
|
## Config file
|
|
55
93
|
|
|
56
94
|
Holocron reads `holocron.config.{json,js,ts}` from the project root
|
|
@@ -103,18 +141,18 @@ A minimal config — for repos with a `package.json` and a GitHub remote
|
|
|
103
141
|
|
|
104
142
|
### repo options
|
|
105
143
|
|
|
106
|
-
Additional `repo` fields recognised by `holocron setup`:
|
|
144
|
+
Additional `repo` fields recognised by `holocron repo setup`:
|
|
107
145
|
|
|
108
|
-
| Field | Type | Description
|
|
109
|
-
| ----------------- | --------------------------------------- |
|
|
110
|
-
| `repo.teams` | `Array<string \| { slug, permission }>` | GitHub teams granted repo access. String shorthand defaults to `push` (Write). `holocron setup` also writes `.github/CODEOWNERS` for teams with `push`/`maintain`/`admin`. |
|
|
111
|
-
| `repo.topics` | `string[]` | GitHub topics set on the repository.
|
|
112
|
-
| `repo.protection` | `"balanced" \| "strict" \| "none"` | Branch-protection preset applied by `holocron setup`. For `"strict"`, the required status checks are derived from the task manifest — see below. |
|
|
113
|
-
| `repo.properties` | `RepoProperties` | Org-level custom property values synced to the GitHub dashboard.
|
|
146
|
+
| Field | Type | Description |
|
|
147
|
+
| ----------------- | --------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
148
|
+
| `repo.teams` | `Array<string \| { slug, permission }>` | GitHub teams granted repo access. String shorthand defaults to `push` (Write). `holocron repo setup` also writes `.github/CODEOWNERS` for teams with `push`/`maintain`/`admin`. |
|
|
149
|
+
| `repo.topics` | `string[]` | GitHub topics set on the repository. |
|
|
150
|
+
| `repo.protection` | `"balanced" \| "strict" \| "none"` | Branch-protection preset applied by `holocron repo setup`. For `"strict"`, the required status checks are derived from the task manifest — see below. |
|
|
151
|
+
| `repo.properties` | `RepoProperties` | Org-level custom property values synced to the GitHub dashboard. |
|
|
114
152
|
|
|
115
153
|
### Custom properties synced to GitHub
|
|
116
154
|
|
|
117
|
-
`holocron setup` and `holocron sync` both call `syncProperties()` with two
|
|
155
|
+
`holocron repo setup` and `holocron repo sync` both call `syncProperties()` with two
|
|
118
156
|
kinds of fields — always one-way (`holocron.config.ts` → resolved →
|
|
119
157
|
properties; properties are never a second editable source of truth):
|
|
120
158
|
|
|
@@ -142,9 +180,25 @@ Field definitions and derivation heuristics:
|
|
|
142
180
|
`.notes/tech-holocron-platform.spec.md` → "Custom-properties sync — field
|
|
143
181
|
definitions (#677)".
|
|
144
182
|
|
|
183
|
+
The four derived fields' pure computation —
|
|
184
|
+
`deriveProfile()`/`deriveStack()`/`deriveCapabilities()`/`deriveCompliance()`
|
|
185
|
+
(plus their `HolocronProfile`/`DeriveProfileInput`/`PackageJsonLike` types)
|
|
186
|
+
— is exported from this package's public entry point, separate from the
|
|
187
|
+
local-filesystem reads (`readWorkspacePackageJsons()`) that gather their
|
|
188
|
+
inputs here. `@theholocron/sentinel`'s `syncPropertiesFromConfig()` reuses
|
|
189
|
+
these functions unchanged, gathering the same inputs over the GitHub API
|
|
190
|
+
instead (D8 — one derivation, two input sources, not two
|
|
191
|
+
implementations).
|
|
192
|
+
|
|
193
|
+
`missingCapabilities(capabilities)` is `deriveCompliance()`'s sibling —
|
|
194
|
+
same `REQUIRED_BASELINE` table, but returns _which_ required capabilities
|
|
195
|
+
are absent rather than whether any are. `@theholocron/sentinel`'s
|
|
196
|
+
`postCheckRun()` uses it to name what's missing on the check run it
|
|
197
|
+
posts, instead of reporting pass/fail.
|
|
198
|
+
|
|
145
199
|
### Required status checks (`protection: "strict"`)
|
|
146
200
|
|
|
147
|
-
`holocron setup` builds the branch-protection required-check list from the
|
|
201
|
+
`holocron repo setup` builds the branch-protection required-check list from the
|
|
148
202
|
manifest, not a hand-maintained array:
|
|
149
203
|
|
|
150
204
|
- `"DCO"` (hard-prepended), then
|
|
@@ -170,12 +224,32 @@ The generated ruleset also sets `require_extra_approval_for_unattributed_changes
|
|
|
170
224
|
false` — with `required_approving_review_count: 0` and a single maintainer, the
|
|
171
225
|
GitHub default (`true`) is an unsatisfiable block on any PR with an
|
|
172
226
|
unverified/unattributed commit. Repository-admin bypass still covers the real
|
|
173
|
-
risk. And the `codecov.yml` `holocron setup` writes carries `if_not_found:
|
|
227
|
+
risk. And the `codecov.yml` `holocron repo setup` writes carries `if_not_found:
|
|
174
228
|
success` on every status default, so an infra-only PR (dep bump, config,
|
|
175
229
|
lockfile — no coverable change) passes instead of hanging on a `codecov/*`
|
|
176
|
-
required check that never posts. A re-run of `holocron setup` backfills both into
|
|
230
|
+
required check that never posts. A re-run of `holocron repo setup` backfills both into
|
|
177
231
|
an existing repo.
|
|
178
232
|
|
|
233
|
+
### Default branch (`repo.defaultBranch`)
|
|
234
|
+
|
|
235
|
+
```ts
|
|
236
|
+
export default defineConfig({
|
|
237
|
+
repo: { protection: "strict", defaultBranch: "alpha" },
|
|
238
|
+
providers: { source: "github" },
|
|
239
|
+
});
|
|
240
|
+
```
|
|
241
|
+
|
|
242
|
+
`holocron repo setup` syncs GitHub's repo-level default branch (`HEAD`) — what a
|
|
243
|
+
fresh clone checks out, what `gh pr create`/the compare UI target by default,
|
|
244
|
+
and what Sentinel's `validateConfig()` reads (it only ever reads config from
|
|
245
|
+
the repo's default branch, never a PR ref — a deliberate security boundary).
|
|
246
|
+
Omit this field to leave GitHub's current setting untouched; most repos never
|
|
247
|
+
need it. It exists for a repo using a `main`/`alpha` prerelease-channel split
|
|
248
|
+
where active development happens on a non-`main` branch: set this to that
|
|
249
|
+
branch so Sentinel validates against what's actually being developed, then
|
|
250
|
+
change it back once that branch merges to `main` for a stable cut and stops
|
|
251
|
+
being the active branch.
|
|
252
|
+
|
|
179
253
|
### Git hooks
|
|
180
254
|
|
|
181
255
|
```ts
|
|
@@ -186,7 +260,7 @@ export default defineConfig({
|
|
|
186
260
|
});
|
|
187
261
|
```
|
|
188
262
|
|
|
189
|
-
`holocron setup` writes `.husky/pre-push` (runs `holocron ci` before every
|
|
263
|
+
`holocron repo setup` writes `.husky/pre-push` (runs `holocron run ci` before every
|
|
190
264
|
push) and `.husky/pre-commit` (runs `gitleaks protect --staged` + `lint-staged`
|
|
191
265
|
before every commit — scoped to staged changes, not the whole history, so a
|
|
192
266
|
past false positive can't permanently block future commits) and sets
|
|
@@ -197,7 +271,7 @@ setup --hooks` / `--no-hooks` override per run. Bypass one push with `git push
|
|
|
197
271
|
|
|
198
272
|
### Task scripts
|
|
199
273
|
|
|
200
|
-
`holocron sync` reconciles `package.json#scripts` from the `tasks` manifest
|
|
274
|
+
`holocron repo sync` reconciles `package.json#scripts` from the `tasks` manifest
|
|
201
275
|
(merge, never clobber — only the managed keys are touched):
|
|
202
276
|
|
|
203
277
|
```ts
|
|
@@ -232,8 +306,8 @@ export default defineConfig({
|
|
|
232
306
|
`@theholocron/astromech`'s `loadTasksConfig` merges it over
|
|
233
307
|
`holocron.config`'s `tasks` — **task arrays concatenate**
|
|
234
308
|
(`holocron.config` first), the dedicated file **wins on scalars**,
|
|
235
|
-
`extraRequiredChecks` concatenate. `holocron run` / `holocron ci` /
|
|
236
|
-
`holocron setup` / `holocron sync` all read the merged result, so the
|
|
309
|
+
`extraRequiredChecks` concatenate. `holocron run` / `holocron run ci` /
|
|
310
|
+
`holocron repo setup` / `holocron repo sync` all read the merged result, so the
|
|
237
311
|
split is transparent. Useful for keeping the capability/provider config
|
|
238
312
|
and the "what this repo runs" manifest in separate files (this repo does).
|
|
239
313
|
|
|
@@ -260,10 +334,27 @@ job execute the same thing — at a turbo root both are
|
|
|
260
334
|
`turbo run test -- --coverage` (the registry's org-default flags flow through
|
|
261
335
|
turbo's `--`).
|
|
262
336
|
|
|
263
|
-
### `holocron
|
|
337
|
+
### `holocron deploy on-release`
|
|
338
|
+
|
|
339
|
+
```bash
|
|
340
|
+
holocron deploy on-release [--channel <alpha|main>] [--from <commit>] [--to <commit>] [--dry-run]
|
|
341
|
+
```
|
|
342
|
+
|
|
343
|
+
Deploys every workspace package whose own `holocron.config` declares
|
|
344
|
+
`{ name: "delivery.deploy", with: { on: "release" } }` (holocron#930), when the
|
|
345
|
+
release (`--channel`: its prerelease identifier, or `main`/empty for a stable
|
|
346
|
+
release) is on the task's `channel` (default `main`, the stable release) and changes the package or one of its
|
|
347
|
+
`workspace:*` dependencies between `--from` (the previous release's commit,
|
|
348
|
+
omitted when there is none) and `--to` (default `HEAD`). It waits for npm to
|
|
349
|
+
serve the release's new dependency versions, then runs `pnpm --filter <pkg>
|
|
350
|
+
delivery.deploy`. A package that doesn't apply is skipped; a failed deploy
|
|
351
|
+
exits non-zero. The shared `delivery.publish` workflow runs it as its own
|
|
352
|
+
`deploy` job after the release job (opt in with `deploy-on-release: true`).
|
|
353
|
+
|
|
354
|
+
### `holocron run ci`
|
|
264
355
|
|
|
265
356
|
```bash
|
|
266
|
-
holocron ci [--all] [--filter <pkg>] [--dry-run]
|
|
357
|
+
holocron run ci [--all] [--filter <pkg>] [--dry-run]
|
|
267
358
|
```
|
|
268
359
|
|
|
269
360
|
Runs the merge-gating checks locally, in CI order, exiting non-zero on the
|
|
@@ -277,6 +368,23 @@ Order comes from the `CI_ORDER` constant in `@theholocron/astromech`
|
|
|
277
368
|
expands into its sub-jobs (each under its own `audit / …` check context)
|
|
278
369
|
unless the repo ships its own `"audit"` script.
|
|
279
370
|
|
|
371
|
+
### `holocron deploy`
|
|
372
|
+
|
|
373
|
+
`holocron deploy <branch>` (a Git-linked deployment) and `holocron deploy
|
|
374
|
+
--files <dir>` (a directory of build output, no linked repo) both trigger a
|
|
375
|
+
deployment through the configured `deployment` capability, then **wait for
|
|
376
|
+
it to finish**. The command reports success, exit code 0, only when the
|
|
377
|
+
deployment reaches `ready`. A deployment that ends `error` or `cancelled`,
|
|
378
|
+
or is still building after 10 minutes, is a failure: the exit code is
|
|
379
|
+
non-zero and the output includes the provider's own reason
|
|
380
|
+
(`DeploymentRecord.errorMessage`, e.g. Vercel's `Command "npm install"
|
|
381
|
+
exited with 1`). Providers build asynchronously, so accepting a deployment
|
|
382
|
+
isn't the same as it going live (holocron#911).
|
|
383
|
+
|
|
384
|
+
Provider plugins support this through the `Deployment` capability's
|
|
385
|
+
existing `getDeployment(id)`. They should set `errorMessage` on the
|
|
386
|
+
returned `DeploymentRecord` whenever the provider exposes one.
|
|
387
|
+
|
|
280
388
|
### Lint parity
|
|
281
389
|
|
|
282
390
|
The `lint` task takes an optional `linters` array — one list that drives
|
|
@@ -294,7 +402,7 @@ export default defineConfig({
|
|
|
294
402
|
|
|
295
403
|
### Skills installer
|
|
296
404
|
|
|
297
|
-
`holocron setup` can install shared skills from `@theholocron/skills` into the local repo:
|
|
405
|
+
`holocron repo setup` can install shared skills from `@theholocron/skills` into the local repo:
|
|
298
406
|
|
|
299
407
|
```ts
|
|
300
408
|
export default defineConfig({
|
|
@@ -357,16 +465,16 @@ export default acmeConfig;
|
|
|
357
465
|
|
|
358
466
|
## Upgrading
|
|
359
467
|
|
|
360
|
-
- **`holocron upgrade node <to>`** — patches every Node.js version pin
|
|
468
|
+
- **`holocron repo upgrade node <to>`** — patches every Node.js version pin
|
|
361
469
|
(`engines.node`, `.nvmrc`, `.node-version`, `.github/workflows/*`,
|
|
362
470
|
`Dockerfile`, `.tool-versions`) to a new major.
|
|
363
|
-
- **`holocron upgrade deps`** — bumps every `@theholocron/*` pin in
|
|
471
|
+
- **`holocron repo upgrade deps`** — bumps every `@theholocron/*` pin in
|
|
364
472
|
`pnpm-workspace.yaml` (`catalog:` and every named `catalogs.*`) to its latest
|
|
365
473
|
published version, then migrates `holocron.config.ts` from the 7.x preset
|
|
366
474
|
shape (`const { repo, workflows } = node()` + `repo.requiredChecks` +
|
|
367
475
|
`workflows:`) to the current composed-preset API (`const preset = node()` +
|
|
368
476
|
`...preset` + `tasks:` + `extraRequiredChecks:`). Mechanical transforms only —
|
|
369
|
-
review the result, then `pnpm install && holocron ci`. `--pins-only` skips
|
|
477
|
+
review the result, then `pnpm install && holocron run ci`. `--pins-only` skips
|
|
370
478
|
the config migration; `--dry-run` prints without writing.
|
|
371
479
|
|
|
372
480
|
## Auth — fine-grained tokens
|
|
@@ -385,7 +493,7 @@ holocron auth set github.admin ghp_xxx # setup, secrets, environments
|
|
|
385
493
|
|
|
386
494
|
The resolution chain per capability is:
|
|
387
495
|
|
|
388
|
-
```
|
|
496
|
+
```text
|
|
389
497
|
--token flag → HOLOCRON_<FEATURE>_TOKEN env var → keyring("github.<feature>")
|
|
390
498
|
```
|
|
391
499
|
|
|
@@ -402,16 +510,21 @@ holocron auth list # show all stored providers
|
|
|
402
510
|
## Logging
|
|
403
511
|
|
|
404
512
|
Operational output goes through `@theholocron/observability/logger` — separate
|
|
405
|
-
from the user-facing `print` surface.
|
|
513
|
+
from the user-facing `print` surface. Local/interactive runs are quiet by
|
|
514
|
+
default: no colorized or raw structured console output, regardless of the
|
|
515
|
+
resolved level (Axiom shipping, when configured, is unaffected). CI is
|
|
516
|
+
untouched — its existing stdout output still appears. Global flags:
|
|
406
517
|
|
|
407
518
|
```sh
|
|
408
|
-
holocron doctor --
|
|
409
|
-
holocron doctor --
|
|
519
|
+
holocron doctor --log debug # show console output at this level (opt back in)
|
|
520
|
+
holocron doctor --verbose # log level → debug, and shows console output
|
|
521
|
+
holocron doctor --quiet # log level → error, and shows console output
|
|
410
522
|
holocron doctor --debug # print "Run ID: <uuid>" at command end for Axiom lookup
|
|
411
523
|
```
|
|
412
524
|
|
|
413
|
-
Level resolution (highest priority first): `--
|
|
414
|
-
`HOLOCRON_LOG_LEVEL` → `log.level` in `holocron.config` →
|
|
525
|
+
Level resolution (highest priority first): `--log <level>` → `--verbose` /
|
|
526
|
+
`--quiet` → `HOLOCRON_LOG_LEVEL` → `log.level` in `holocron.config` →
|
|
527
|
+
`"info"`.
|
|
415
528
|
|
|
416
529
|
```ts
|
|
417
530
|
export default defineConfig({
|
|
@@ -423,7 +536,16 @@ Axiom shipping activates when a token (`HOLOCRON_AXIOM_TOKEN` / `AXIOM_TOKEN`
|
|
|
423
536
|
→ OS keyring `axiom.<org>` → `axiom`) **and** a dataset
|
|
424
537
|
(`HOLOCRON_AXIOM_DATASET` / `AXIOM_DATASET` → `log.axiom.dataset` in
|
|
425
538
|
`holocron.config`) both resolve; env vars win. The token is never read from a
|
|
426
|
-
config file.
|
|
539
|
+
config file.
|
|
540
|
+
|
|
541
|
+
The dataset side of that resolution is **execution-context-aware** (ADR-0012):
|
|
542
|
+
a `global`-context command (`clone`, `new`, `auth set`, `upgrade node`, `plugin
|
|
543
|
+
create`, …) always ships to holocron's own dataset regardless of `$PWD` — it
|
|
544
|
+
isn't "about" any repo, so routing it through whichever repo's `.envrc`
|
|
545
|
+
happens to be active would be wrong. `repo-aware` / `workspace` commands
|
|
546
|
+
(`doctor`, `deploy`, `sync`, …) keep the env-var/config chain above, so a
|
|
547
|
+
per-repo `HOLOCRON_AXIOM_DATASET` — e.g. via a `.envrc` + `direnv` — separates
|
|
548
|
+
each consuming repo's logs. See the [logging guide](https://docs.theholocron.dev/holocron/logging/).
|
|
427
549
|
|
|
428
550
|
### Telemetry
|
|
429
551
|
|
|
@@ -457,10 +579,35 @@ holds the orchestration + the Holocron-specific credential resolution
|
|
|
457
579
|
(`telemetry/resolve.ts`). See the
|
|
458
580
|
[telemetry guide](https://docs.theholocron.dev/holocron/telemetry/).
|
|
459
581
|
|
|
582
|
+
### ESLint bundle options
|
|
583
|
+
|
|
584
|
+
Most repos need nothing here — `@theholocron/eslint-config`'s `library()`
|
|
585
|
+
bundle resolves with zero committed file (Bucket A: `eslint --config
|
|
586
|
+
<shared path>`, no per-repo `eslint.config.ts` needed). A package with a
|
|
587
|
+
genuine, deliberate exception — e.g. Web Crypto globals a Node-targeted
|
|
588
|
+
package still needs, exempted via `library()`'s own `browserPackages`
|
|
589
|
+
option in that package's own `eslint.config.ts` — should also declare the
|
|
590
|
+
same paths in `holocron.config`'s `eslint.browserPackages`:
|
|
591
|
+
|
|
592
|
+
```ts
|
|
593
|
+
export default defineConfig({
|
|
594
|
+
eslint: {
|
|
595
|
+
browserPackages: ["packages/github-client/src/app-auth"],
|
|
596
|
+
},
|
|
597
|
+
});
|
|
598
|
+
```
|
|
599
|
+
|
|
600
|
+
This doesn't replace the package's own `eslint.config.ts` (local/CI linting
|
|
601
|
+
still resolves that file directly) — it's the signal Sentinel's centralized
|
|
602
|
+
static-analysis check (holocron#849/#858) reads instead, since that check
|
|
603
|
+
never reads a PR's own committed config files. Without it, Sentinel flags a
|
|
604
|
+
false-positive `eslint-plugin-n` node-builtins finding on exactly the files
|
|
605
|
+
the local override exists to exempt.
|
|
606
|
+
|
|
460
607
|
## What's in here
|
|
461
608
|
|
|
462
|
-
- `src/capabilities
|
|
463
|
-
implement
|
|
609
|
+
- `src/plugin/capabilities.ts` — the 18 capability interfaces that
|
|
610
|
+
providers implement
|
|
464
611
|
- `src/config.ts` — config schema, `defineConfig`, `resolveConfig`,
|
|
465
612
|
`CapabilityConfigPackage`
|
|
466
613
|
- `src/config/load-config.ts` — `loadConfig` — reads `holocron.config.*`
|
|
@@ -472,14 +619,14 @@ holds the orchestration + the Holocron-specific credential resolution
|
|
|
472
619
|
capability config packages, builds the capability registry
|
|
473
620
|
- `src/cli.ts` — yargs entry, dispatches subcommands. `holocron run` / `ci` are
|
|
474
621
|
delegated to [`@theholocron/astromech`](../astromech) (`createAstromech`).
|
|
475
|
-
`holocron sync` / `holocron setup` write each repo's `.github/workflows/*.yml`
|
|
476
|
-
thin callers from `astromech.thinCallers()`; `holocron sync
|
|
622
|
+
`holocron repo sync` / `holocron repo setup` write each repo's `.github/workflows/*.yml`
|
|
623
|
+
thin callers from `astromech.thinCallers()`; `holocron sync github` pushes the
|
|
477
624
|
reusable `workflow_call` implementations + composite actions from
|
|
478
625
|
`astromech.reusableTemplates()` to `theholocron/.github` (a pure sync target —
|
|
479
626
|
never hand-edit its `.github/workflows/*`).
|
|
480
|
-
- `src/commands/` — `setup`, `sync`, `doctor`, `deploy`, `
|
|
481
|
-
`secrets sync`, `publish`, `bump-versions`, `sync
|
|
482
|
-
`upgrade deps`, `plugin
|
|
627
|
+
- `src/commands/` — `repo setup`, `repo sync`, `doctor`, `deploy`, `secrets set`,
|
|
628
|
+
`secrets sync`, `package publish`, `package bump-versions`, `sync github`,
|
|
629
|
+
`repo upgrade node`, `repo upgrade deps`, `new plugin`, `auth`
|
|
483
630
|
- `src/interactive-menu.ts` — the interactive fallback: `COMMAND_REGISTRY`,
|
|
484
631
|
`launchMenu` (Layers 1–2, picks + spawns a fresh `holocron <command>`),
|
|
485
632
|
`promptForPositionals` (Layer 3, called inline from each leaf command's
|