@intentius/chant 0.124.100 → 0.124.101
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/dist/action-pins.d.ts +2 -0
- package/dist/action-pins.js +3 -0
- package/dist/ci-detect.d.ts +13 -0
- package/dist/ci-detect.js +12 -0
- package/dist/ci-system.d.ts +66 -0
- package/dist/ci-system.js +61 -0
- package/dist/cli/handlers/build.js +27 -0
- package/dist/cli/handlers/release-doctor.d.ts +12 -0
- package/dist/cli/handlers/release-doctor.js +118 -0
- package/dist/cli/handlers/release-init.d.ts +10 -0
- package/dist/cli/handlers/release-init.js +342 -0
- package/dist/cli/handlers/release.d.ts +42 -1
- package/dist/cli/handlers/release.js +656 -31
- package/dist/cli/handlers/run-generate.js +11 -0
- package/dist/cli/main.d.ts +2 -0
- package/dist/cli/main.js +44 -101
- package/dist/cli/parse-args.js +48 -0
- package/dist/cli/registry.d.ts +16 -0
- package/dist/cli/release-commands/artifacts.d.ts +3 -0
- package/dist/cli/release-commands/artifacts.js +14 -0
- package/dist/cli/release-commands/candidates.d.ts +3 -0
- package/dist/cli/release-commands/candidates.js +16 -0
- package/dist/cli/release-commands/changed.d.ts +3 -0
- package/dist/cli/release-commands/changed.js +14 -0
- package/dist/cli/release-commands/compose.d.ts +3 -0
- package/dist/cli/release-commands/compose.js +16 -0
- package/dist/cli/release-commands/cut.d.ts +3 -0
- package/dist/cli/release-commands/cut.js +49 -0
- package/dist/cli/release-commands/doctor.d.ts +3 -0
- package/dist/cli/release-commands/doctor.js +14 -0
- package/dist/cli/release-commands/export.d.ts +3 -0
- package/dist/cli/release-commands/export.js +12 -0
- package/dist/cli/release-commands/images.d.ts +3 -0
- package/dist/cli/release-commands/images.js +13 -0
- package/dist/cli/release-commands/index.d.ts +8 -0
- package/dist/cli/release-commands/index.js +52 -0
- package/dist/cli/release-commands/init.d.ts +3 -0
- package/dist/cli/release-commands/init.js +16 -0
- package/dist/cli/release-commands/list.d.ts +3 -0
- package/dist/cli/release-commands/list.js +10 -0
- package/dist/cli/release-commands/next.d.ts +3 -0
- package/dist/cli/release-commands/next.js +13 -0
- package/dist/cli/release-commands/publish.d.ts +3 -0
- package/dist/cli/release-commands/publish.js +22 -0
- package/dist/cli/release-commands/stamp.d.ts +3 -0
- package/dist/cli/release-commands/stamp.js +15 -0
- package/dist/cli/release-commands/status.d.ts +3 -0
- package/dist/cli/release-commands/status.js +17 -0
- package/dist/cli/release-commands/tag.d.ts +3 -0
- package/dist/cli/release-commands/tag.js +12 -0
- package/dist/cli/release-commands/types.d.ts +20 -0
- package/dist/cli/release-commands/types.js +1 -0
- package/dist/cli/release-commands/verify.d.ts +3 -0
- package/dist/cli/release-commands/verify.js +15 -0
- package/dist/cli/release-commands/workflow.d.ts +3 -0
- package/dist/cli/release-commands/workflow.js +13 -0
- package/dist/components/cli-support.d.ts +1 -1
- package/dist/components/cli-support.js +1 -1
- package/dist/config-environments.d.ts +8 -1
- package/dist/config-environments.js +2 -0
- package/dist/config.d.ts +294 -9
- package/dist/config.js +100 -5
- package/dist/floor-table.data.js +15 -1
- package/dist/forge-remote.d.ts +13 -0
- package/dist/forge-remote.js +15 -0
- package/dist/lexicon.d.ts +41 -2
- package/dist/lifecycle/__fixtures__/publish-fakes.d.ts +62 -0
- package/dist/lifecycle/__fixtures__/publish-fakes.js +270 -3
- package/dist/lifecycle/publish-attachments.d.ts +2 -1
- package/dist/lifecycle/publish-attachments.js +19 -2
- package/dist/lifecycle/publish-cargo.d.ts +99 -0
- package/dist/lifecycle/publish-cargo.js +412 -0
- package/dist/lifecycle/publish-credentials.d.ts +1 -1
- package/dist/lifecycle/publish-credentials.js +8 -0
- package/dist/lifecycle/publish-declaration.d.ts +199 -4
- package/dist/lifecycle/publish-declaration.js +200 -9
- package/dist/lifecycle/publish-forge.d.ts +45 -2
- package/dist/lifecycle/publish-forge.js +434 -34
- package/dist/lifecycle/publish-git-ssh.d.ts +15 -0
- package/dist/lifecycle/publish-git-ssh.js +30 -4
- package/dist/lifecycle/publish-github.d.ts +40 -2
- package/dist/lifecycle/publish-github.js +100 -3
- package/dist/lifecycle/publish-homebrew.d.ts +7 -9
- package/dist/lifecycle/publish-homebrew.js +34 -197
- package/dist/lifecycle/publish-index.d.ts +141 -0
- package/dist/lifecycle/publish-index.js +719 -0
- package/dist/lifecycle/publish-marketplace.js +77 -0
- package/dist/lifecycle/publish-mcp-registry.d.ts +66 -0
- package/dist/lifecycle/publish-mcp-registry.js +306 -0
- package/dist/lifecycle/publish-npm.js +165 -2
- package/dist/lifecycle/publish-oci.d.ts +34 -1
- package/dist/lifecycle/publish-oci.js +246 -7
- package/dist/lifecycle/publish-pypi.d.ts +136 -0
- package/dist/lifecycle/publish-pypi.js +657 -0
- package/dist/lifecycle/publish-record.d.ts +6 -3
- package/dist/lifecycle/publish-record.js +6 -3
- package/dist/lifecycle/publish-signing.d.ts +147 -0
- package/dist/lifecycle/publish-signing.js +257 -0
- package/dist/lifecycle/publish-targets.d.ts +27 -1
- package/dist/lifecycle/publish-targets.js +80 -0
- package/dist/lifecycle/publish-tauri.js +43 -0
- package/dist/lifecycle/publish-train-names.d.ts +54 -0
- package/dist/lifecycle/publish-train-names.js +118 -0
- package/dist/lifecycle/publish-verify.d.ts +121 -0
- package/dist/lifecycle/publish-verify.js +130 -0
- package/dist/lifecycle/query.js +8 -0
- package/dist/lifecycle/release-artifacts.d.ts +212 -0
- package/dist/lifecycle/release-artifacts.js +571 -0
- package/dist/lifecycle/release-changelog.d.ts +13 -1
- package/dist/lifecycle/release-changelog.js +35 -2
- package/dist/lifecycle/release-cut.d.ts +58 -3
- package/dist/lifecycle/release-cut.js +132 -34
- package/dist/lifecycle/release-doctor.d.ts +113 -0
- package/dist/lifecycle/release-doctor.js +996 -0
- package/dist/lifecycle/release-green.d.ts +86 -0
- package/dist/lifecycle/release-green.js +286 -0
- package/dist/lifecycle/release-init.d.ts +255 -0
- package/dist/lifecycle/release-init.js +859 -0
- package/dist/lifecycle/release-intents.d.ts +73 -0
- package/dist/lifecycle/release-intents.js +128 -0
- package/dist/lifecycle/release-next.d.ts +111 -0
- package/dist/lifecycle/release-next.js +252 -0
- package/dist/lifecycle/release-prerelease.d.ts +19 -0
- package/dist/lifecycle/release-prerelease.js +30 -0
- package/dist/lifecycle/release-publish.d.ts +256 -10
- package/dist/lifecycle/release-publish.js +246 -34
- package/dist/lifecycle/release-status-change.d.ts +226 -0
- package/dist/lifecycle/release-status-change.js +478 -0
- package/dist/lifecycle/release-status.d.ts +11 -0
- package/dist/lifecycle/release-status.js +1 -1
- package/dist/lifecycle/release-store.d.ts +73 -2
- package/dist/lifecycle/release-store.js +32 -1
- package/dist/lifecycle/release-tag.d.ts +142 -0
- package/dist/lifecycle/release-tag.js +323 -0
- package/dist/lifecycle/release-verify.d.ts +73 -1
- package/dist/lifecycle/release-verify.js +117 -2
- package/dist/lifecycle/release-version-formats.d.ts +73 -0
- package/dist/lifecycle/release-version-formats.js +570 -0
- package/dist/lifecycle/release-version.d.ts +58 -10
- package/dist/lifecycle/release-version.js +164 -36
- package/dist/lifecycle/release-workstation.d.ts +3 -2
- package/dist/lifecycle/release-workstation.js +3 -2
- package/dist/op/generate-pipeline.js +1 -1
- package/dist/pr-forge-base.js +4 -2
- package/dist/pr-forge.d.ts +20 -2
- package/dist/pr-forge.js +46 -10
- package/dist/release-floors.d.ts +8 -1
- package/dist/release-floors.js +9 -2
- package/dist/tool-pins.d.ts +38 -0
- package/dist/tool-pins.js +54 -0
- package/dist/wave-runtime.mjs +337 -334
- package/dist/workspace/ci-forge.d.ts +17 -0
- package/dist/workspace/ci-forge.js +17 -0
- package/dist/workspace/ci-init.js +1 -1
- package/dist/workspace/composites.schema.json +1 -0
- package/dist/workspace/declaration.d.ts +8 -0
- package/dist/workspace/declaration.js +12 -0
- package/dist/workspace/declaration.schema.json +8 -0
- package/dist/workspace/environments.d.ts +2 -0
- package/dist/workspace/environments.js +1 -1
- package/dist/workspace/identity-gate-rule.d.ts +61 -5
- package/dist/workspace/identity-gate-rule.js +81 -12
- package/dist/workspace/member-pipeline.d.ts +2 -1
- package/dist/workspace/member-pipeline.js +5 -2
- package/dist/workspace/reason-codes.d.ts +2 -0
- package/dist/workspace/reason-codes.js +3 -1
- package/dist/workspace/release-changed.d.ts +75 -4
- package/dist/workspace/release-changed.js +205 -34
- package/dist/workspace/release-changed.schema.json +20 -2
- package/dist/workspace/release-steps/artifacts.d.ts +7 -0
- package/dist/workspace/release-steps/artifacts.js +45 -0
- package/dist/workspace/release-steps/builds.d.ts +12 -0
- package/dist/workspace/release-steps/builds.js +38 -0
- package/dist/workspace/release-steps/doctor.d.ts +8 -0
- package/dist/workspace/release-steps/doctor.js +14 -0
- package/dist/workspace/release-steps/goreleaser.d.ts +16 -0
- package/dist/workspace/release-steps/goreleaser.js +36 -0
- package/dist/workspace/release-steps/green.d.ts +3 -0
- package/dist/workspace/release-steps/green.js +6 -0
- package/dist/workspace/release-steps/images.d.ts +22 -0
- package/dist/workspace/release-steps/images.js +59 -0
- package/dist/workspace/release-steps/index.d.ts +9 -0
- package/dist/workspace/release-steps/index.js +46 -0
- package/dist/workspace/release-steps/pypi.d.ts +15 -0
- package/dist/workspace/release-steps/pypi.js +21 -0
- package/dist/workspace/release-steps/qemu.d.ts +21 -0
- package/dist/workspace/release-steps/qemu.js +35 -0
- package/dist/workspace/release-steps/signing.d.ts +18 -0
- package/dist/workspace/release-steps/signing.js +30 -0
- package/dist/workspace/release-steps/stamp.d.ts +3 -0
- package/dist/workspace/release-steps/stamp.js +4 -0
- package/dist/workspace/release-steps/targets.d.ts +31 -0
- package/dist/workspace/release-steps/targets.js +40 -0
- package/dist/workspace/release-steps/types.d.ts +104 -0
- package/dist/workspace/release-steps/types.js +2 -0
- package/dist/workspace/release-steps/verify.d.ts +3 -0
- package/dist/workspace/release-steps/verify.js +4 -0
- package/dist/workspace/release-toolchains.d.ts +59 -0
- package/dist/workspace/release-toolchains.js +133 -0
- package/dist/workspace/release-train-workflow.d.ts +29 -0
- package/dist/workspace/release-train-workflow.js +85 -0
- package/dist/workspace/release-train.d.ts +3 -1
- package/dist/workspace/release-train.js +20 -3
- package/dist/workspace/release-workflow.d.ts +160 -61
- package/dist/workspace/release-workflow.js +539 -193
- package/dist/workspace/releases.schema.json +70 -1
- package/dist/workspace/search-contract.d.ts +1 -1
- package/dist/workspace/security.js +9 -2
- package/dist/workspace/train-cut.d.ts +182 -0
- package/dist/workspace/train-cut.js +482 -0
- package/dist/workspace/train-prepare.d.ts +61 -0
- package/dist/workspace/train-prepare.js +267 -0
- package/dist/workspace/train-publish.d.ts +177 -0
- package/dist/workspace/train-publish.js +575 -0
- package/dist/workspace/train-range-labels.d.ts +33 -0
- package/dist/workspace/train-range-labels.js +109 -0
- package/dist/workspace/trust/seal.d.ts +13 -3
- package/dist/workspace/trust/seal.js +14 -4
- package/dist/workspace/work-cli.d.ts +3 -2
- package/dist/workspace/work-cli.js +3 -2
- package/dist/workspace/workspace-ledger.d.ts +14 -1
- package/dist/workspace/workspace-ledger.js +33 -7
- package/package.json +1 -1
|
@@ -154,6 +154,32 @@
|
|
|
154
154
|
"$ref": "#/$defs/target"
|
|
155
155
|
}
|
|
156
156
|
},
|
|
157
|
+
"publishes": {
|
|
158
|
+
"type": "array",
|
|
159
|
+
"items": {
|
|
160
|
+
"type": "object",
|
|
161
|
+
"required": [
|
|
162
|
+
"target",
|
|
163
|
+
"kind",
|
|
164
|
+
"destination"
|
|
165
|
+
],
|
|
166
|
+
"properties": {
|
|
167
|
+
"target": {
|
|
168
|
+
"type": "string",
|
|
169
|
+
"description": "The target's key: its type and the first 16 hex digits of the SHA-256 of its declaration."
|
|
170
|
+
},
|
|
171
|
+
"kind": {
|
|
172
|
+
"type": "string",
|
|
173
|
+
"description": "The declaration's type, such as npm or forge."
|
|
174
|
+
},
|
|
175
|
+
"destination": {
|
|
176
|
+
"type": "string",
|
|
177
|
+
"description": "Where it publishes, as release publish prints it."
|
|
178
|
+
}
|
|
179
|
+
}
|
|
180
|
+
},
|
|
181
|
+
"description": "Added by #5149, written by chant 0.124.101 and newer. An artifact release, cut with no environments: the release.publish targets, in the declared order. targets is then empty. Absent on a release cut from environments."
|
|
182
|
+
},
|
|
157
183
|
"cuts": {
|
|
158
184
|
"type": "array",
|
|
159
185
|
"description": "Each cut of the release, oldest first.",
|
|
@@ -338,7 +364,11 @@
|
|
|
338
364
|
"string",
|
|
339
365
|
"null"
|
|
340
366
|
],
|
|
341
|
-
"description": "Added by #4031, written by chant 0.124.28 and newer. The cut's armored ssh signature (ssh-keygen -Y sign, namespace chant-release) by the actor's key, over the release digest, the label (empty for none), the actor and the timestamp, joined by LF with no final newline. Null for an unsigned cut. A reader checks it against .chant/allowed_signers at base; signatureCheck is chant's own check."
|
|
367
|
+
"description": "Added by #4031, written by chant 0.124.28 and newer. The cut's armored ssh signature (ssh-keygen -Y sign, namespace chant-release) by the actor's key, over the release digest, the label (empty for none), the actor and the timestamp, joined by LF with no final newline. Null for an unsigned cut. A reader checks it against .chant/allowed_signers at base; signatureCheck is chant's own check. From chant 0.124.101 (#5177) a signed cut also signs its green-gate record: the four lines, then seal:2 and gate:<green, override and lane as JSON with sorted keys>, and the line carries sealVersion 2."
|
|
368
|
+
},
|
|
369
|
+
"sealVersion": {
|
|
370
|
+
"const": 2,
|
|
371
|
+
"description": "Added by #5177, written by chant 0.124.101 and newer. The signature signs payload version 2, which covers the cut's green, override and lane. Absent on an unsigned cut and on a cut signed over version 1, whose gate record is not signed."
|
|
342
372
|
},
|
|
343
373
|
"signatureCheck": {
|
|
344
374
|
"type": "object",
|
|
@@ -366,6 +396,13 @@
|
|
|
366
396
|
},
|
|
367
397
|
"reason": {
|
|
368
398
|
"type": "string"
|
|
399
|
+
},
|
|
400
|
+
"gate": {
|
|
401
|
+
"enum": [
|
|
402
|
+
"signed",
|
|
403
|
+
"unsigned"
|
|
404
|
+
],
|
|
405
|
+
"description": "Added within contract version 1 by #5177, written by chant 0.124.101 and newer. signed: the signature verifies and covers the cut's green-gate record (sealVersion 2). unsigned: it does not verify, the cut has none, or it was signed over version 1 and the gate record could have changed since."
|
|
369
406
|
}
|
|
370
407
|
}
|
|
371
408
|
},
|
|
@@ -445,6 +482,38 @@
|
|
|
445
482
|
}
|
|
446
483
|
},
|
|
447
484
|
"description": "Added by #4693, written by chant 0.124.64 and newer. The commit was not green, and release cut --override-green cut it under a person's override, which it spent. Absent on a cut of a green commit."
|
|
485
|
+
},
|
|
486
|
+
"green": {
|
|
487
|
+
"type": "object",
|
|
488
|
+
"required": [
|
|
489
|
+
"source"
|
|
490
|
+
],
|
|
491
|
+
"properties": {
|
|
492
|
+
"source": {
|
|
493
|
+
"enum": [
|
|
494
|
+
"chant",
|
|
495
|
+
"forge-checks",
|
|
496
|
+
"none"
|
|
497
|
+
],
|
|
498
|
+
"description": "release.green: a chant green tag, the forge's checks, or no gate."
|
|
499
|
+
},
|
|
500
|
+
"tag": {
|
|
501
|
+
"type": "string",
|
|
502
|
+
"description": "For chant: the green tag the commit carried, ci/green/<sha> or ci/green-<lane>/<sha>."
|
|
503
|
+
},
|
|
504
|
+
"forge": {
|
|
505
|
+
"type": "string",
|
|
506
|
+
"description": "For forge-checks: github, gitlab or forgejo."
|
|
507
|
+
},
|
|
508
|
+
"checks": {
|
|
509
|
+
"type": "array",
|
|
510
|
+
"items": {
|
|
511
|
+
"type": "string"
|
|
512
|
+
},
|
|
513
|
+
"description": "For forge-checks: the checks that passed, by name, sorted."
|
|
514
|
+
}
|
|
515
|
+
},
|
|
516
|
+
"description": "Added by #5149, written by chant 0.124.101 and newer. The green gate the commit passed. Absent on a cut under an override and on a cut written before."
|
|
448
517
|
}
|
|
449
518
|
}
|
|
450
519
|
},
|
|
@@ -29,7 +29,7 @@ export type SearchErrorCode = (typeof SEARCH_ERROR_CODES)[number];
|
|
|
29
29
|
export declare const WORKSPACE_SEARCH_ERROR_CODES: readonly ["declaration-missing", "declaration-ambiguous", "declaration-unparseable", "declaration-invalid", "placement-invalid", "reader-too-old", "root-chant-required", "not-a-git-repository", "revision-unknown", "live-at-revision", "snapshot-at-revision", "query-invalid", "usage-invalid"];
|
|
30
30
|
export type WorkspaceSearchErrorCode = (typeof WORKSPACE_SEARCH_ERROR_CODES)[number];
|
|
31
31
|
/** Every `error.code` a `search` document can carry, in either form. */
|
|
32
|
-
export declare const SEARCH_DOCUMENT_ERROR_CODES: ("agent-unknown" | "amend-id-immutable" | "amend-supersede-instead" | "answer-field-unsupported" | "answer-in-steward-turn" | "answer-never-over-mcp" | "answer-not-answered" | "answer-not-candidate" | "answer-point-changed" | "answer-point-unknown" | "answer-points-unreadable" | "asset-drift" | "asset-missing" | "asset-stale" | "box-capability-unbrokered" | "box-credential-declared" | "box-fountain-callback-undeclared" | "box-intent-unconstrained" | "box-intent-unknown" | "box-isolation-collision" | "box-isolation-literal" | "box-none" | "box-several" | "build-failed" | "bump-invalid" | "capability-not-derivable" | "change-out-of-scope" | "change-uncovered" | "chant-config-left" | "chant-dependency" | "chant-in-ci" | "choudoufu-steps-missing" | "ci-branch-route-differs" | "ci-branch-unknown" | "ci-green-undeclared" | "ci-workflow-apply-in-green" | "ci-workflow-green-undeclared" | "ci-workflow-no-components" | "ci-workflow-no-environments" | "ci-workflow-no-pre-merge" | "ci-workflow-pipeline-differs" | "ci-workflow-pipeline-missing" | "ci-workflow-publish-missing" | "ci-workflow-ungated-env" | "command-failed" | "commit-unlinked" | "commit-wrongly-linked" | "composites-no-chant-member" | "composites-no-component" | "composites-none-declared" | "declaration-ambiguous" | "declaration-invalid" | "declaration-missing" | "declaration-not-other" | "declaration-unparseable" | "diagram-render-drift" | "diagram-render-missing" | "diagram-source-missing" | "dir-missing" | "env-required" | "envelope-invalid" | "envelope-unreadable" | "envelope-untrusted" | "environment-invalid" | "environment-unknown" | "environments-component-undeclared" | "environments-ledger-undeclared" | "environments-ledger-unreadable" | "environments-none-declared" | "evidence-payload-type" | "evidence-runner-mismatch" | "evidence-statement-invalid" | "executor-config-unreadable" | "executor-none-declared" | "exit-failed" | "factory-box-missing" | "factory-member-unknown" | "filter-invalid" | "flag-stale" | "flag-work-unknown" | "gate-approval-unbased" | "gates-ledger-unreadable" | "gates-no-gate-ledger" | "gates-no-ledger" | "index-unavailable" | "instances-each-value" | "instances-form-unread" | "instances-merge" | "instances-module-uncounted" | "instances-over-limit" | "instances-value-unknown" | "intent-artifact-unpinned" | "intent-commit-bare" | "intent-commit-join-conflict" | "intent-commit-undecided" | "intent-constraint-coarse" | "intent-constraint-lost" | "intent-decision-contested" | "intent-decision-provisional" | "intent-decision-superseded-live" | "intent-decision-unimplemented" | "intent-evidence-unpinned" | "intent-history-shallow" | "intent-pin-drifted" | "intent-pin-missing" | "intent-pin-stale" | "intent-plugin-failed" | "intent-record-unknown" | "intent-region-invalid" | "intent-region-unconstrained" | "intent-symbol-ambiguous" | "intent-symbol-unknown" | "intent-symbol-unsupported" | "intent-trailer-unverified" | "intent-why-no-decision" | "intent-why-no-run" | "intent-why-run-ambiguous" | "intent-why-uncommitted" | "intent-work-blocked" | "intent-work-open-decided-code" | "ir-version-unsupported" | "kind-invalid" | "kind-not-run" | "kind-probe-failed" | "kind-unreadable" | "lease-held" | "lease-not-held" | "lease-push-rejected" | "lease-race" | "lease-token-mismatch" | "ledger-malformed" | "ledger-unreadable" | "lexicon-has-no-mapping" | "lexicon-not-loaded" | "lexicon-unsupported" | "listing-box-missing" | "listing-cover-invalid" | "listing-member-unknown" | "live-at-revision" | "location-missing" | "lock-invalid" | "manual-step-open" | "member-chant-too-old" | "member-exists" | "member-required" | "member-unknown" | "missing-dir" | "native-missing" | "native-unreadable" | "needed-by" | "no-deploy-command" | "no-drift-read" | "no-lexicon" | "no-matches" | "not-a-git-repository" | "output-unreadable" | "patch-path-invalid" | "paths-changed" | "placement-invalid" | "point-candidates-invalid" | "point-decider-failed" | "point-inputs-invalid" | "point-unknown" | "points-invalid" | "points-undeclared" | "principal-unidentified" | "publish-answer-invalid" | "publish-failed" | "publish-member-unknown" | "publish-none" | "publish-refused" | "publish-unrecorded" | "query-invalid" | "quorum-not-met" | "range-broken-by" | "ratify-quorum-not-met" | "read-unsupported" | "reader-too-old" | "record-closed" | "record-conflict" | "record-id-duplicate" | "record-id-taken" | "record-id-unallocatable" | "record-no-evidence" | "record-not-found" | "record-path-unmatched" | "record-ratified-below-quorum" | "record-remediates-not-closed" | "record-remediates-unknown" | "record-schema-invalid" | "record-seal-mismatch" | "record-sign-failed" | "record-state-not-initial" | "record-supersedes-conflict" | "record-supersedes-pending" | "record-supersedes-unknown" | "record-unattested" | "record-unparseable" | "ref-evidence-missing" | "ref-evidence-stale" | "ref-update-invalid" | "resource-unsupported" | "review-agent" | "review-decider" | "review-duplicate" | "review-note-required" | "review-older-digest" | "review-sign-failed" | "review-unattested" | "review-undigested" | "review-unsupported" | "revision-unknown" | "root-chant-required" | "rotation-first-version" | "rotation-invalid" | "rotation-missing" | "rotation-previous-mismatch" | "rotation-threshold-not-met" | "rotation-threshold-unsatisfiable" | "rotation-unparseable" | "rotation-version-skew" | "run-ended" | "run-exists" | "run-not-ended" | "run-statement-invalid" | "run-statement-mismatch" | "run-statement-signer-mismatch" | "run-unknown" | "runner-exists" | "runner-key-invalid" | "runner-key-is-signer" | "runner-key-unlisted" | "runner-unknown" | "runs-ledger-malformed" | "runs-no-ledger" | "runtimes-config-unreadable" | "runtimes-lexicon-unreadable" | "schema-id-mismatch" | "schema-invalid" | "schema-unreadable" | "seal-missing" | "seal-signature-invalid" | "seal-signer-unlisted" | "seal-unverifiable" | "security-attribution-any" | "security-component-no-sbom" | "security-component-no-verify" | "security-gate-unsigned" | "security-publish-allows-unsigned" | "security-publish-no-provenance" | "security-release-gate-missing" | "security-review-not-required" | "security-runner-start-no-key" | "security-runner-start-no-role" | "security-runner-untrusted" | "security-sbom-disabled" | "security-sbom-unsourced" | "security-signed-since-unset" | "security-signers-missing" | "security-tick-no-key" | "security-trust-unreadable" | "session-not-open" | "session-seal-mismatch" | "session-unknown" | "session-verdict-unknown-record" | "signers-file-missing" | "signers-removed" | "since-rev-unknown" | "since-session-open" | "since-session-unknown" | "snapshot-at-revision" | "snapshot-unavailable" | "source-harvest-not-proposed" | "source-transcript-drift" | "squash-unfollowed" | "steward-runs-unreadable" | "stewards-conflict" | "stewards-unreadable" | "table-unknown" | "trust-config-invalid" | "trust-conflict" | "trust-policy-unreadable" | "unknown-kind" | "usage-invalid" | "wip-branch-other" | "wip-no-branch" | "wip-none" | "wip-policy-none" | "wip-race" | "wip-remote-unknown" | "wip-snapshot-unknown" | "work-acceptance-self-verified" | "work-acceptance-unmet" | "work-closed-without-date" | "work-contract-undecided" | "work-contract-unknown" | "work-criterion-unknown" | "work-done-gap-open" | "work-done-unpinned" | "work-evidence-ops-mismatch" | "work-evidence-ops-missing" | "work-evidence-ops-unfinished" | "work-implements-undecided" | "work-implements-unknown" | "work-item-closed" | "work-item-unknown" | "work-kind-ambiguous" | "work-kind-missing" | "work-needs-cycle" | "work-needs-unknown" | "work-tier-unknown" | "write-input-invalid" | "write-lock-not-held" | "write-lock-timeout" | "write-scope-class-unknown" | "write-scope-kind" | "write-scope-member" | "write-scope-protected" | "write-usage-invalid")[];
|
|
32
|
+
export declare const SEARCH_DOCUMENT_ERROR_CODES: ("agent-unknown" | "amend-id-immutable" | "amend-supersede-instead" | "answer-field-unsupported" | "answer-in-steward-turn" | "answer-never-over-mcp" | "answer-not-answered" | "answer-not-candidate" | "answer-point-changed" | "answer-point-unknown" | "answer-points-unreadable" | "asset-drift" | "asset-missing" | "asset-stale" | "box-capability-unbrokered" | "box-credential-declared" | "box-fountain-callback-undeclared" | "box-intent-unconstrained" | "box-intent-unknown" | "box-isolation-collision" | "box-isolation-literal" | "box-none" | "box-several" | "build-failed" | "bump-invalid" | "capability-not-derivable" | "change-out-of-scope" | "change-uncovered" | "chant-config-left" | "chant-dependency" | "chant-in-ci" | "choudoufu-steps-missing" | "ci-branch-route-differs" | "ci-branch-unknown" | "ci-green-undeclared" | "ci-workflow-apply-in-green" | "ci-workflow-green-undeclared" | "ci-workflow-no-components" | "ci-workflow-no-environments" | "ci-workflow-no-pre-merge" | "ci-workflow-pipeline-differs" | "ci-workflow-pipeline-missing" | "ci-workflow-publish-missing" | "ci-workflow-ungated-env" | "command-failed" | "commit-unlinked" | "commit-wrongly-linked" | "composites-no-chant-member" | "composites-no-component" | "composites-none-declared" | "declaration-ambiguous" | "declaration-invalid" | "declaration-missing" | "declaration-not-other" | "declaration-unparseable" | "diagram-render-drift" | "diagram-render-missing" | "diagram-source-missing" | "dir-missing" | "env-required" | "envelope-invalid" | "envelope-unreadable" | "envelope-untrusted" | "environment-invalid" | "environment-unknown" | "environments-component-undeclared" | "environments-ledger-undeclared" | "environments-ledger-unreadable" | "environments-none-declared" | "evidence-payload-type" | "evidence-runner-mismatch" | "evidence-statement-invalid" | "executor-config-unreadable" | "executor-none-declared" | "exit-failed" | "factory-box-missing" | "factory-member-unknown" | "filter-invalid" | "flag-stale" | "flag-work-unknown" | "gate-approval-unbased" | "gates-ledger-unreadable" | "gates-no-gate-ledger" | "gates-no-ledger" | "index-unavailable" | "instances-each-value" | "instances-form-unread" | "instances-merge" | "instances-module-uncounted" | "instances-over-limit" | "instances-value-unknown" | "intent-artifact-unpinned" | "intent-commit-bare" | "intent-commit-join-conflict" | "intent-commit-undecided" | "intent-constraint-coarse" | "intent-constraint-lost" | "intent-decision-contested" | "intent-decision-provisional" | "intent-decision-superseded-live" | "intent-decision-unimplemented" | "intent-evidence-unpinned" | "intent-history-shallow" | "intent-invalid" | "intent-pending" | "intent-pin-drifted" | "intent-pin-missing" | "intent-pin-stale" | "intent-plugin-failed" | "intent-record-unknown" | "intent-region-invalid" | "intent-region-unconstrained" | "intent-symbol-ambiguous" | "intent-symbol-unknown" | "intent-symbol-unsupported" | "intent-trailer-unverified" | "intent-why-no-decision" | "intent-why-no-run" | "intent-why-run-ambiguous" | "intent-why-uncommitted" | "intent-work-blocked" | "intent-work-open-decided-code" | "ir-version-unsupported" | "kind-invalid" | "kind-not-run" | "kind-probe-failed" | "kind-unreadable" | "lease-held" | "lease-not-held" | "lease-push-rejected" | "lease-race" | "lease-token-mismatch" | "ledger-malformed" | "ledger-unreadable" | "lexicon-has-no-mapping" | "lexicon-not-loaded" | "lexicon-unsupported" | "listing-box-missing" | "listing-cover-invalid" | "listing-member-unknown" | "live-at-revision" | "location-missing" | "lock-invalid" | "manual-step-open" | "member-chant-too-old" | "member-exists" | "member-required" | "member-unknown" | "missing-dir" | "native-missing" | "native-unreadable" | "needed-by" | "no-deploy-command" | "no-drift-read" | "no-lexicon" | "no-matches" | "not-a-git-repository" | "output-unreadable" | "patch-path-invalid" | "paths-changed" | "placement-invalid" | "point-candidates-invalid" | "point-decider-failed" | "point-inputs-invalid" | "point-unknown" | "points-invalid" | "points-undeclared" | "principal-unidentified" | "publish-answer-invalid" | "publish-failed" | "publish-member-unknown" | "publish-none" | "publish-refused" | "publish-unrecorded" | "query-invalid" | "quorum-not-met" | "range-broken-by" | "ratify-quorum-not-met" | "read-unsupported" | "reader-too-old" | "record-closed" | "record-conflict" | "record-id-duplicate" | "record-id-taken" | "record-id-unallocatable" | "record-no-evidence" | "record-not-found" | "record-path-unmatched" | "record-ratified-below-quorum" | "record-remediates-not-closed" | "record-remediates-unknown" | "record-schema-invalid" | "record-seal-mismatch" | "record-sign-failed" | "record-state-not-initial" | "record-supersedes-conflict" | "record-supersedes-pending" | "record-supersedes-unknown" | "record-unattested" | "record-unparseable" | "ref-evidence-missing" | "ref-evidence-stale" | "ref-update-invalid" | "resource-unsupported" | "review-agent" | "review-decider" | "review-duplicate" | "review-note-required" | "review-older-digest" | "review-sign-failed" | "review-unattested" | "review-undigested" | "review-unsupported" | "revision-unknown" | "root-chant-required" | "rotation-first-version" | "rotation-invalid" | "rotation-missing" | "rotation-previous-mismatch" | "rotation-threshold-not-met" | "rotation-threshold-unsatisfiable" | "rotation-unparseable" | "rotation-version-skew" | "run-ended" | "run-exists" | "run-not-ended" | "run-statement-invalid" | "run-statement-mismatch" | "run-statement-signer-mismatch" | "run-unknown" | "runner-exists" | "runner-key-invalid" | "runner-key-is-signer" | "runner-key-unlisted" | "runner-unknown" | "runs-ledger-malformed" | "runs-no-ledger" | "runtimes-config-unreadable" | "runtimes-lexicon-unreadable" | "schema-id-mismatch" | "schema-invalid" | "schema-unreadable" | "seal-missing" | "seal-signature-invalid" | "seal-signer-unlisted" | "seal-unverifiable" | "security-attribution-any" | "security-component-no-sbom" | "security-component-no-verify" | "security-gate-unsigned" | "security-publish-allows-unsigned" | "security-publish-no-provenance" | "security-release-gate-missing" | "security-review-not-required" | "security-runner-start-no-key" | "security-runner-start-no-role" | "security-runner-untrusted" | "security-sbom-disabled" | "security-sbom-unsourced" | "security-signed-since-unset" | "security-signers-missing" | "security-tick-no-key" | "security-trust-unreadable" | "session-not-open" | "session-seal-mismatch" | "session-unknown" | "session-verdict-unknown-record" | "signers-file-missing" | "signers-removed" | "since-rev-unknown" | "since-session-open" | "since-session-unknown" | "snapshot-at-revision" | "snapshot-unavailable" | "source-harvest-not-proposed" | "source-transcript-drift" | "squash-unfollowed" | "steward-runs-unreadable" | "stewards-conflict" | "stewards-unreadable" | "table-unknown" | "trust-config-invalid" | "trust-conflict" | "trust-policy-unreadable" | "unknown-kind" | "usage-invalid" | "wip-branch-other" | "wip-no-branch" | "wip-none" | "wip-policy-none" | "wip-race" | "wip-remote-unknown" | "wip-snapshot-unknown" | "work-acceptance-self-verified" | "work-acceptance-unmet" | "work-closed-without-date" | "work-contract-undecided" | "work-contract-unknown" | "work-criterion-unknown" | "work-done-gap-open" | "work-done-unpinned" | "work-evidence-ops-mismatch" | "work-evidence-ops-missing" | "work-evidence-ops-unfinished" | "work-implements-undecided" | "work-implements-unknown" | "work-item-closed" | "work-item-unknown" | "work-kind-ambiguous" | "work-kind-missing" | "work-needs-cycle" | "work-needs-unknown" | "work-tier-unknown" | "write-input-invalid" | "write-lock-not-held" | "write-lock-timeout" | "write-scope-class-unknown" | "write-scope-kind" | "write-scope-member" | "write-scope-protected" | "write-usage-invalid")[];
|
|
33
33
|
/**
|
|
34
34
|
* Why a member of `chant workspace search` has no answer. A member that ran
|
|
35
35
|
* and refused carries its own {@link SEARCH_ERROR_CODES} code; the rest are
|
|
@@ -10,8 +10,11 @@
|
|
|
10
10
|
* - `verified-releases`: `chant release publish` refuses a release with no
|
|
11
11
|
* verified signature, as the `release` gate in `identity.gates` does, and
|
|
12
12
|
* `chant components promote --release` verifies the release first.
|
|
13
|
-
*
|
|
14
|
-
*
|
|
13
|
+
* `chant release cut` refuses `release.green: "none"` (#5149).
|
|
14
|
+
* - `supply-chain`: a publish without OIDC provenance warns, a target
|
|
15
|
+
* with no SBOM source is refused (`publish-sbom-missing`), the OCI and
|
|
16
|
+
* forge targets sign with Sigstore (`release.signing`, #5164), and `chant
|
|
17
|
+
* release cut` refuses `release.green: "none"` (#5149).
|
|
15
18
|
* - `who-ran-it`: `chant ci tick` refuses to tag without a runner key.
|
|
16
19
|
* - `review-rules`: `chant components pr-apply` counts an approval only from
|
|
17
20
|
* someone who approved the pull request on the forge, as
|
|
@@ -79,8 +82,12 @@ export const SECURITY_FEATURES = [
|
|
|
79
82
|
{ feature: "Publish refuses an unsigned release", byDefault: "off: publishes and records `signature: unsigned`", setting: "`identity.gates.release`", group: "verified-releases", codes: ["security-signers-missing", "security-publish-allows-unsigned"] },
|
|
80
83
|
{ feature: "Signed cut in the release gate's class", byDefault: "off", setting: "`identity.gates.release` with a `class`", group: "verified-releases", codes: ["security-release-gate-missing"] },
|
|
81
84
|
{ feature: "Promote verifies the release", byDefault: "off: `chant release verify` on demand", setting: "`chant release verify`", group: "verified-releases", codes: [] },
|
|
85
|
+
// #5149: a cut with no green gate.
|
|
86
|
+
{ feature: "Cut refuses `release.green: \"none\"`", byDefault: "off: cuts with a warning and records `green: none`", setting: "`identity.gates.release`", group: "verified-releases", codes: [] },
|
|
82
87
|
{ feature: "SBOM on every target", byDefault: "off: a target with no SBOM source publishes without one", setting: "`sbom` on the target", group: "supply-chain", codes: ["security-sbom-disabled", "security-sbom-unsourced"] },
|
|
83
88
|
{ feature: "OIDC provenance", byDefault: "off: a plan field", setting: "`--require-provenance`", group: "supply-chain", codes: ["security-publish-no-provenance"] },
|
|
89
|
+
{ feature: "Cut needs a green gate", byDefault: "off: `release.green: \"none\"` cuts with a warning", setting: "`release.green` other than `none`", group: "supply-chain", codes: [] },
|
|
90
|
+
{ feature: "Sigstore signatures and SLSA provenance on images and forge assets", byDefault: "off: nothing is signed", setting: "`release.signing`", group: "supply-chain", codes: [] },
|
|
84
91
|
{ feature: "SBOM and verify steps on components", byDefault: "off", setting: "a `generate-sbom` or `verify` step", group: "supply-chain", codes: ["security-component-no-sbom", "security-component-no-verify"] },
|
|
85
92
|
{ feature: "Signed green tags and runs", byDefault: "off: every tag counts", setting: "`ci.green.signedSince`", group: "who-ran-it", codes: ["security-signed-since-unset"] },
|
|
86
93
|
{ feature: "Trusted runner keys", byDefault: "off", setting: "`.chant/trust.json` with a runner role", group: "who-ran-it", codes: ["security-runner-untrusted"] },
|
|
@@ -0,0 +1,182 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Cutting a release train (#5154): `chant workspace train cut <env> [--at
|
|
3
|
+
* <sha>] [--levels <levels>] [--yes] [--no-push] [--json]`, run in the root of
|
|
4
|
+
* a workspace whose `chant` members are the releasable units (each package
|
|
5
|
+
* of a monorepo, say), with `release.train` in the root's `chant.config.ts`.
|
|
6
|
+
*
|
|
7
|
+
* One command does what a hand-written release script did:
|
|
8
|
+
*
|
|
9
|
+
* 1. The commit: `--at` (the trunk's tip without it). A commit a
|
|
10
|
+
* `release-train/<env>/<id>` tag already names is released, and nothing
|
|
11
|
+
* more happens.
|
|
12
|
+
* 2. The members: those `chant release changed` lists at the commit, with
|
|
13
|
+
* its dependency closure, each at the level `--levels` types for it or,
|
|
14
|
+
* without one, the level its conventional commits and intent files give.
|
|
15
|
+
* A member already cut from this commit (a run that stopped part way) is
|
|
16
|
+
* taken at the label it was cut with, and is not cut again.
|
|
17
|
+
* 3. The labels: each member's next label is floored past every version it
|
|
18
|
+
* already has: the labels in its ledger, its release tags (`release.tag`,
|
|
19
|
+
* or `release/<member>/<label>`), the `release.legacyTags` tags, the
|
|
20
|
+
* `version` of each package its `release.version` names at the commit,
|
|
21
|
+
* and every version the npm registry lists for the packages it publishes.
|
|
22
|
+
* So a label is never one a registry already holds. Under `first:
|
|
23
|
+
* "together"` the first train of the environment cuts every member at one
|
|
24
|
+
* label, one past the highest of all of them and of the root member's
|
|
25
|
+
* own ledger.
|
|
26
|
+
* 4. `release.train.check`: shell lines run once the labels are known and
|
|
27
|
+
* before anything is cut, with `CHANT_RELEASE_COMMIT`, `CHANT_TRAIN_ENV`
|
|
28
|
+
* and `CHANT_TRAIN_PLAN` (a JSON file of the members and labels).
|
|
29
|
+
* 5. `chant release cut <label> --at <commit> --yes` in each member's
|
|
30
|
+
* directory, in publish order. Each cut pushes its record and tags the
|
|
31
|
+
* commit locally.
|
|
32
|
+
* 6. The train: every member at the release this run cut, the rest at their
|
|
33
|
+
* newest, written to `chant/lifecycle` and pushed.
|
|
34
|
+
* 7. One atomic push of every member's tag and `release-train/<env>/<id>` on
|
|
35
|
+
* the commit. A workflow on that tag publishes the train.
|
|
36
|
+
*
|
|
37
|
+
* Without `--yes` it plans: it prints the members and labels, runs each
|
|
38
|
+
* cut's dry run, and cuts, records, tags and pushes nothing.
|
|
39
|
+
*/
|
|
40
|
+
import { type ReleaseBump } from "./release-changed.js";
|
|
41
|
+
/** `release.train` in a workspace root's `chant.config.ts` (#5154). */
|
|
42
|
+
export interface ReleaseTrainConfig {
|
|
43
|
+
/** The environment the train is recorded for, and the middle of its tag `release-train/<env>/<id>`. */
|
|
44
|
+
env: string;
|
|
45
|
+
/**
|
|
46
|
+
* The first train of the environment: `each` (default) labels every member
|
|
47
|
+
* from its own versions; `together` cuts every member at one label, one past
|
|
48
|
+
* the highest version any of them has, so packages that shipped at one
|
|
49
|
+
* version until now start from it together.
|
|
50
|
+
*/
|
|
51
|
+
first?: "each" | "together";
|
|
52
|
+
/** Shell lines run at the root once the labels are known and before any cut, with `CHANT_RELEASE_COMMIT`, `CHANT_TRAIN_ENV` and `CHANT_TRAIN_PLAN`. One that fails stops the train with nothing cut. */
|
|
53
|
+
check?: string[];
|
|
54
|
+
/**
|
|
55
|
+
* The command `chant workspace train prepare` runs in each workspace
|
|
56
|
+
* package a published member depends on and the train does not publish
|
|
57
|
+
* here, once, dependencies first. Default: the package's `prepack` script,
|
|
58
|
+
* else its `build` script. `false` builds nothing.
|
|
59
|
+
*/
|
|
60
|
+
buildDependencies?: string | false;
|
|
61
|
+
}
|
|
62
|
+
/** Why a train cut stopped. */
|
|
63
|
+
export declare class TrainCutError extends Error {
|
|
64
|
+
readonly code: string;
|
|
65
|
+
readonly fix?: string | undefined;
|
|
66
|
+
constructor(code: string, message: string, fix?: string | undefined);
|
|
67
|
+
}
|
|
68
|
+
/** One member of a planned train. */
|
|
69
|
+
export interface TrainCutMember {
|
|
70
|
+
member: string;
|
|
71
|
+
/** The member's directory from the workspace root. */
|
|
72
|
+
dir: string;
|
|
73
|
+
label: string;
|
|
74
|
+
/** Why it is in the train: a `release changed` reason (`paths-changed`, `needed-by <member>`, ...), `first-train`, or `already-cut`. */
|
|
75
|
+
why: string;
|
|
76
|
+
/** The level its label was bumped by, or null for a resumed member. */
|
|
77
|
+
bump: ReleaseBump | null;
|
|
78
|
+
/** Where the level came from: `typed`, `commits`, `intents`, `default`, `first-train` or `already-cut`. */
|
|
79
|
+
bumpFrom: string;
|
|
80
|
+
/** The highest version the member already has anywhere, or null for none. */
|
|
81
|
+
floor: string | null;
|
|
82
|
+
/** True when this commit already has the member's release, from a run that stopped part way. */
|
|
83
|
+
resumed: boolean;
|
|
84
|
+
}
|
|
85
|
+
export interface TrainCutPlan {
|
|
86
|
+
env: string;
|
|
87
|
+
commit: string;
|
|
88
|
+
/** True when this is the environment's first train and `first: "together"` gave every member one label. */
|
|
89
|
+
first: boolean;
|
|
90
|
+
/** The `release-train/<env>/<id>` tag already on the commit, when it is released; then `members` is empty. */
|
|
91
|
+
released: string | null;
|
|
92
|
+
members: TrainCutMember[];
|
|
93
|
+
}
|
|
94
|
+
/** The levels typed for a train: one for every member, and one per member. */
|
|
95
|
+
export interface TrainLevels {
|
|
96
|
+
all?: ReleaseBump;
|
|
97
|
+
members: Record<string, ReleaseBump>;
|
|
98
|
+
}
|
|
99
|
+
/**
|
|
100
|
+
* Parse `--levels`: words separated by spaces or commas, each `major`,
|
|
101
|
+
* `minor` or `patch` (every member), `<member>=<level>`, or `auto` (the
|
|
102
|
+
* levels the commits and intent files give; the same as nothing).
|
|
103
|
+
*/
|
|
104
|
+
export declare function parseTrainLevels(text: string | undefined): TrainLevels;
|
|
105
|
+
/** The highest of `versions`, or null. */
|
|
106
|
+
export declare function highestVersion(versions: Iterable<string>): string | null;
|
|
107
|
+
/** Lists the versions a registry holds for an npm package; null when it has never heard of it. Throws when the registry can't say. */
|
|
108
|
+
export type NpmVersionsReader = (name: string, registry: string | undefined) => string[] | null;
|
|
109
|
+
/** `npm view <name> versions --json`, as npm prints it: a string for one version, an array for several. */
|
|
110
|
+
export declare function npmVersions(npm?: string, env?: NodeJS.ProcessEnv): NpmVersionsReader;
|
|
111
|
+
/** What the floor of one member reads. */
|
|
112
|
+
interface FloorSources {
|
|
113
|
+
top: string;
|
|
114
|
+
commit: string;
|
|
115
|
+
memberDir: string;
|
|
116
|
+
registry: NpmVersionsReader;
|
|
117
|
+
}
|
|
118
|
+
/** Every version the member at `memberDir` has anywhere (#5154): ledger labels, release tags, legacy tags, package versions at the commit, registry versions. */
|
|
119
|
+
export declare function memberVersions(s: FloorSources): Promise<string[]>;
|
|
120
|
+
export interface TrainCutQuery {
|
|
121
|
+
/** Any directory of the workspace whose train it cuts. */
|
|
122
|
+
cwd: string;
|
|
123
|
+
env: string;
|
|
124
|
+
/** The commit; the trunk's tip without it. */
|
|
125
|
+
at?: string;
|
|
126
|
+
levels?: TrainLevels;
|
|
127
|
+
/** Reads the registry's versions. Default: {@link npmVersions}. */
|
|
128
|
+
registry?: NpmVersionsReader;
|
|
129
|
+
}
|
|
130
|
+
/** The release config of the workspace root, with `release.train` checked. */
|
|
131
|
+
export declare function trainConfigAt(root: string, env: string): Promise<ReleaseTrainConfig>;
|
|
132
|
+
/** Plan a train: the commit, the members and their labels (#5154). Writes nothing. */
|
|
133
|
+
export declare function planTrainCut(q: TrainCutQuery): Promise<TrainCutPlan>;
|
|
134
|
+
/** What the cut of one member printed, as `chant release cut --json` prints it. */
|
|
135
|
+
export interface MemberCutResult {
|
|
136
|
+
/** The tag the cut made (or found) on the commit, or null when it made none. */
|
|
137
|
+
tag: string | null;
|
|
138
|
+
}
|
|
139
|
+
/** Cuts one member: `chant release cut <label> --at <commit>`, with `--yes` when `yes`. */
|
|
140
|
+
export type MemberCutter = (m: TrainCutMember, commit: string, o: {
|
|
141
|
+
root: string;
|
|
142
|
+
yes: boolean;
|
|
143
|
+
}) => Promise<MemberCutResult>;
|
|
144
|
+
/** The default {@link MemberCutter}: this chant's `release cut` in the member's directory. */
|
|
145
|
+
export declare const spawnMemberCut: MemberCutter;
|
|
146
|
+
export interface TrainCutRun extends TrainCutQuery {
|
|
147
|
+
/** Cut, record, tag and push. Without it the cuts run as dry runs and nothing is written. */
|
|
148
|
+
yes?: boolean;
|
|
149
|
+
/** Record and tag locally, and push nothing (the cuts still push their records). */
|
|
150
|
+
noPush?: boolean;
|
|
151
|
+
/** The remote the tags and the record go to. Default `origin`. */
|
|
152
|
+
remote?: string;
|
|
153
|
+
actor?: string;
|
|
154
|
+
cutter?: MemberCutter;
|
|
155
|
+
/** Runs the `release.train.check` lines. Default: `sh -c` each one. */
|
|
156
|
+
runCheck?: (line: string, o: {
|
|
157
|
+
cwd: string;
|
|
158
|
+
env: NodeJS.ProcessEnv;
|
|
159
|
+
}) => number;
|
|
160
|
+
/** A line of progress. */
|
|
161
|
+
say?: (line: string) => void;
|
|
162
|
+
now?: () => Date;
|
|
163
|
+
}
|
|
164
|
+
export interface TrainCutOutcome extends TrainCutPlan {
|
|
165
|
+
/** The tag each member's cut made, by member. */
|
|
166
|
+
tags: Record<string, string>;
|
|
167
|
+
/** The train recorded, or null on a plan, a released commit or an empty train. */
|
|
168
|
+
train: {
|
|
169
|
+
id: string;
|
|
170
|
+
trainDigest: string;
|
|
171
|
+
} | null;
|
|
172
|
+
/** `release-train/<env>/<id>`, or null. */
|
|
173
|
+
trainTag: string | null;
|
|
174
|
+
pushed: boolean;
|
|
175
|
+
/** Why the record did not reach the remote, when it did not. */
|
|
176
|
+
pushWarning?: string;
|
|
177
|
+
}
|
|
178
|
+
/** Plan, and with `yes` cut, record, tag and push, a release train (#5154). */
|
|
179
|
+
export declare function cutTrain(q: TrainCutRun): Promise<TrainCutOutcome>;
|
|
180
|
+
/** `chant workspace train cut <env>` (#5154). */
|
|
181
|
+
export declare function runTrainCut(ctx: import("../cli/registry.js").CommandContext, words: string[]): Promise<number>;
|
|
182
|
+
export {};
|