@intentius/chant 0.124.101 → 0.124.103

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.
Files changed (109) hide show
  1. package/dist/ci-evidence-claims.d.ts +12 -0
  2. package/dist/ci-evidence-claims.js +12 -0
  3. package/dist/cli/commands/onboard.js +8 -8
  4. package/dist/cli/handlers/release-init.js +53 -19
  5. package/dist/cli/handlers/release.d.ts +1 -1
  6. package/dist/cli/handlers/release.js +12 -9
  7. package/dist/cli/main.js +13 -2
  8. package/dist/cli/parse-args.js +5 -0
  9. package/dist/cli/registry.d.ts +2 -0
  10. package/dist/cli/release-commands/cut.js +4 -3
  11. package/dist/cli/release-commands/init.js +4 -1
  12. package/dist/cli/release-commands/workflow.js +4 -2
  13. package/dist/cloud-lister/index.d.ts +4 -1
  14. package/dist/cloud-lister/index.js +2 -1
  15. package/dist/cloud-lister/kubernetes-components.d.ts +56 -0
  16. package/dist/cloud-lister/kubernetes-components.js +641 -0
  17. package/dist/cloud-lister/kubernetes.d.ts +18 -0
  18. package/dist/cloud-lister/kubernetes.js +26 -1
  19. package/dist/cloud-lister/mask.d.ts +5 -1
  20. package/dist/cloud-lister/mask.js +14 -5
  21. package/dist/config-import.d.ts +1 -1
  22. package/dist/config-import.js +6 -2
  23. package/dist/config-sandbox.d.ts +1 -1
  24. package/dist/config-sandbox.js +3 -3
  25. package/dist/config.d.ts +75 -1
  26. package/dist/config.js +27 -2
  27. package/dist/deep-observation.js +9 -3
  28. package/dist/floor-table.data.js +13 -6
  29. package/dist/lexicon.d.ts +4 -2
  30. package/dist/lifecycle/__fixtures__/package-files.d.ts +32 -0
  31. package/dist/lifecycle/__fixtures__/package-files.js +72 -0
  32. package/dist/lifecycle/__fixtures__/publish-fakes.js +5 -0
  33. package/dist/lifecycle/publish-credentials.d.ts +1 -1
  34. package/dist/lifecycle/publish-credentials.js +5 -0
  35. package/dist/lifecycle/publish-declaration.d.ts +123 -0
  36. package/dist/lifecycle/publish-declaration.js +141 -2
  37. package/dist/lifecycle/publish-helm.d.ts +83 -0
  38. package/dist/lifecycle/publish-helm.js +451 -0
  39. package/dist/lifecycle/publish-maven.d.ts +79 -0
  40. package/dist/lifecycle/publish-maven.js +363 -0
  41. package/dist/lifecycle/publish-mcp-registry.js +1 -2
  42. package/dist/lifecycle/publish-npm.d.ts +27 -1
  43. package/dist/lifecycle/publish-npm.js +52 -2
  44. package/dist/lifecycle/publish-nuget.d.ts +93 -0
  45. package/dist/lifecycle/publish-nuget.js +376 -0
  46. package/dist/lifecycle/publish-oci.d.ts +57 -1
  47. package/dist/lifecycle/publish-oci.js +1 -1
  48. package/dist/lifecycle/publish-package-files.d.ts +16 -0
  49. package/dist/lifecycle/publish-package-files.js +39 -0
  50. package/dist/lifecycle/publish-pypi.d.ts +2 -0
  51. package/dist/lifecycle/publish-pypi.js +1 -1
  52. package/dist/lifecycle/publish-rubygems.d.ts +84 -0
  53. package/dist/lifecycle/publish-rubygems.js +365 -0
  54. package/dist/lifecycle/publish-targets.d.ts +10 -0
  55. package/dist/lifecycle/publish-targets.js +22 -0
  56. package/dist/lifecycle/publish-train-names.d.ts +4 -1
  57. package/dist/lifecycle/publish-train-names.js +5 -0
  58. package/dist/lifecycle/release-artifacts.d.ts +80 -2
  59. package/dist/lifecycle/release-artifacts.js +241 -5
  60. package/dist/lifecycle/release-cut.d.ts +6 -1
  61. package/dist/lifecycle/release-cut.js +15 -0
  62. package/dist/lifecycle/release-doctor.js +208 -6
  63. package/dist/lifecycle/release-init-registries.d.ts +48 -0
  64. package/dist/lifecycle/release-init-registries.js +97 -0
  65. package/dist/lifecycle/release-init.d.ts +22 -2
  66. package/dist/lifecycle/release-init.js +139 -13
  67. package/dist/lifecycle/release-next.js +1 -2
  68. package/dist/lifecycle/release-publish.d.ts +1 -1
  69. package/dist/lifecycle/release-publish.js +1 -1
  70. package/dist/lifecycle/release-tag.js +1 -2
  71. package/dist/op/local-executor.d.ts +1 -1
  72. package/dist/op/local-executor.js +2 -2
  73. package/dist/op/op-waves-evidence.js +9 -2
  74. package/dist/release-floors.d.ts +1 -1
  75. package/dist/release-floors.js +1 -1
  76. package/dist/sensitive-key.d.ts +12 -0
  77. package/dist/sensitive-key.js +52 -0
  78. package/dist/tool-pins.d.ts +2 -0
  79. package/dist/tool-pins.js +12 -0
  80. package/dist/ts-loader.d.ts +8 -0
  81. package/dist/ts-loader.js +19 -0
  82. package/dist/wave-runtime.mjs +325 -325
  83. package/dist/workspace/lexicon-outputs.d.ts +1 -1
  84. package/dist/workspace/lexicon-outputs.js +1 -1
  85. package/dist/workspace/release-steps/index.js +4 -0
  86. package/dist/workspace/release-steps/nfpm.d.ts +13 -0
  87. package/dist/workspace/release-steps/nfpm.js +29 -0
  88. package/dist/workspace/release-steps/nuget.d.ts +14 -0
  89. package/dist/workspace/release-steps/nuget.js +16 -0
  90. package/dist/workspace/release-steps/targets.d.ts +2 -2
  91. package/dist/workspace/release-steps/targets.js +3 -3
  92. package/dist/workspace/release-train-workflow.d.ts +27 -2
  93. package/dist/workspace/release-train-workflow.js +171 -14
  94. package/dist/workspace/release-train.js +5 -1
  95. package/dist/workspace/release-workflow.d.ts +39 -3
  96. package/dist/workspace/release-workflow.js +80 -24
  97. package/dist/workspace/train-artifacts.d.ts +107 -0
  98. package/dist/workspace/train-artifacts.js +239 -0
  99. package/dist/workspace/train-cut.d.ts +14 -2
  100. package/dist/workspace/train-cut.js +49 -7
  101. package/dist/workspace/train-prepare.d.ts +6 -3
  102. package/dist/workspace/train-prepare.js +54 -8
  103. package/dist/workspace/train-publish.d.ts +9 -0
  104. package/dist/workspace/train-publish.js +29 -4
  105. package/dist/workspace/train-shell.d.ts +5 -0
  106. package/dist/workspace/train-shell.js +17 -0
  107. package/dist/workspace/trust/check-evidence-report.d.ts +3 -7
  108. package/dist/workspace/trust/check-evidence-report.js +3 -7
  109. package/package.json +1 -1
@@ -43,3 +43,15 @@ export declare const REFERENCE_KEYS: ReadonlySet<string>;
43
43
  * could be one never passes on the strength of its key.
44
44
  */
45
45
  export declare function isReferenceField(key: string, value: unknown): boolean;
46
+ /**
47
+ * The readable view of a Secret reference in a pod spec (chant#5252), or
48
+ * undefined when `pattern` is not one or `value` names no Secret. The name
49
+ * stays (`volumes[].secret.secretName`, `secretKeyRef.name`,
50
+ * `envFrom[].secretRef.name`, `imagePullSecrets[].name`) and every other
51
+ * field becomes `masked`, so a Secret's key names and options stay hidden
52
+ * as before. Both masking passes call it (the lister's and the deep
53
+ * observation's), on the declared and the live side alike, so the two sides
54
+ * still compare equal. A value that is already `masked` is not a view and
55
+ * gives undefined.
56
+ */
57
+ export declare function podSecretNameView(pattern: string, value: unknown, masked: string): unknown;
@@ -66,3 +66,55 @@ export function isReferenceField(key, value) {
66
66
  return value.length > 0 && value.every(isPointer);
67
67
  return isPointer(value);
68
68
  }
69
+ /**
70
+ * Where a Kubernetes pod spec names a Secret (chant#5252), as an index-erased
71
+ * pattern: a Pod's `spec`, a workload's `spec.template.spec`, or a CronJob's
72
+ * `spec.jobTemplate.spec.template.spec`, then one of the four places that
73
+ * name a Secret. Each maps to the field that holds the name.
74
+ */
75
+ const POD_SPEC = String.raw `^spec\.(?:(?:jobTemplate\.spec\.)?template\.spec\.)?`;
76
+ const CONTAINERS = String.raw `(?:initContainers|containers|ephemeralContainers)\[\]\.`;
77
+ const SECRET_NAME_HOLDERS = [
78
+ { re: new RegExp(`${POD_SPEC}volumes\\[\\]\\.secret$`), field: "secretName" },
79
+ { re: new RegExp(`${POD_SPEC}volumes\\[\\]\\.projected\\.sources\\[\\]\\.secret$`), field: "name" },
80
+ { re: new RegExp(`${POD_SPEC}${CONTAINERS}env\\[\\]\\.valueFrom\\.secretKeyRef$`), field: "name" },
81
+ { re: new RegExp(`${POD_SPEC}${CONTAINERS}envFrom\\[\\]\\.secretRef$`), field: "name" },
82
+ { re: new RegExp(`${POD_SPEC}imagePullSecrets$`), field: "name", list: true },
83
+ ];
84
+ function nameView(value, field, masked) {
85
+ if (typeof value !== "object" || value === null || Array.isArray(value))
86
+ return undefined;
87
+ const obj = value;
88
+ const name = obj[field];
89
+ if (typeof name !== "string" || name === "" || name === "<masked>" || name === "[REDACTED]")
90
+ return undefined;
91
+ const out = {};
92
+ for (const k of Object.keys(obj))
93
+ out[k] = k === field ? name : masked;
94
+ return out;
95
+ }
96
+ /**
97
+ * The readable view of a Secret reference in a pod spec (chant#5252), or
98
+ * undefined when `pattern` is not one or `value` names no Secret. The name
99
+ * stays (`volumes[].secret.secretName`, `secretKeyRef.name`,
100
+ * `envFrom[].secretRef.name`, `imagePullSecrets[].name`) and every other
101
+ * field becomes `masked`, so a Secret's key names and options stay hidden
102
+ * as before. Both masking passes call it (the lister's and the deep
103
+ * observation's), on the declared and the live side alike, so the two sides
104
+ * still compare equal. A value that is already `masked` is not a view and
105
+ * gives undefined.
106
+ */
107
+ export function podSecretNameView(pattern, value, masked) {
108
+ for (const h of SECRET_NAME_HOLDERS) {
109
+ if (!h.re.test(pattern))
110
+ continue;
111
+ if (h.list) {
112
+ if (!Array.isArray(value) || value.length === 0)
113
+ return undefined;
114
+ const views = value.map((v) => nameView(v, h.field, masked));
115
+ return views.every((v) => v !== undefined) ? views : undefined;
116
+ }
117
+ return nameView(value, h.field, masked);
118
+ }
119
+ return undefined;
120
+ }
@@ -11,6 +11,7 @@
11
11
  *
12
12
  * curl -sL https://github.com/sigstore/cosign/releases/download/v3.1.4/cosign_checksums.txt | grep -E 'cosign-linux-(amd64|arm64)$'
13
13
  * gh release download v2.19.0 -R goreleaser/goreleaser -p checksums.txt -O - | grep -E 'goreleaser_Linux_(x86_64|arm64)\.tar\.gz$'
14
+ * gh release download v2.48.0 -R goreleaser/nfpm -p checksums.txt -O - | grep -E 'nfpm_2.48.0_Linux_(x86_64|arm64)\.tar\.gz$'
14
15
  */
15
16
  export interface ToolPin {
16
17
  /** The tool's name: the binary the step leaves in its directory. */
@@ -28,6 +29,7 @@ export interface ToolPin {
28
29
  export declare const TOOL_PINS: {
29
30
  readonly cosign: ToolPin;
30
31
  readonly goreleaser: ToolPin;
32
+ readonly nfpm: ToolPin;
31
33
  };
32
34
  /**
33
35
  * Shell that downloads `pin` for `platform` into `dir`, checks its SHA-256
package/dist/tool-pins.js CHANGED
@@ -11,6 +11,7 @@
11
11
  *
12
12
  * curl -sL https://github.com/sigstore/cosign/releases/download/v3.1.4/cosign_checksums.txt | grep -E 'cosign-linux-(amd64|arm64)$'
13
13
  * gh release download v2.19.0 -R goreleaser/goreleaser -p checksums.txt -O - | grep -E 'goreleaser_Linux_(x86_64|arm64)\.tar\.gz$'
14
+ * gh release download v2.48.0 -R goreleaser/nfpm -p checksums.txt -O - | grep -E 'nfpm_2.48.0_Linux_(x86_64|arm64)\.tar\.gz$'
14
15
  */
15
16
  const cosign = (version, sums) => ({
16
17
  name: "cosign",
@@ -23,6 +24,12 @@ const goreleaser = (version, sums) => ({
23
24
  archive: true,
24
25
  platforms: Object.fromEntries(Object.entries(sums).map(([platform, [asset, sha256]]) => [platform, { url: `https://github.com/goreleaser/goreleaser/releases/download/${version}/${asset}`, sha256 }])),
25
26
  });
27
+ const nfpm = (version, sums) => ({
28
+ name: "nfpm",
29
+ version,
30
+ archive: true,
31
+ platforms: Object.fromEntries(Object.entries(sums).map(([platform, [asset, sha256]]) => [platform, { url: `https://github.com/goreleaser/nfpm/releases/download/${version}/${asset}`, sha256 }])),
32
+ });
26
33
  export const TOOL_PINS = {
27
34
  // #5164: Sigstore signing at publish. v3.1.4 was released 2026-10-20; the sums are its cosign_checksums.txt's.
28
35
  cosign: cosign("v3.1.4", {
@@ -34,6 +41,11 @@ export const TOOL_PINS = {
34
41
  "linux/amd64": ["goreleaser_Linux_x86_64.tar.gz", "ebc3194ad1d1b1787614405285a0039665cd4c5bd3305215a1b201600f90630b"],
35
42
  "linux/arm64": ["goreleaser_Linux_arm64.tar.gz", "ef33741b684c9f62d6a21e7a3c8b051f139ea7b1d301693b67cc819c46226d53"],
36
43
  }),
44
+ // #5233: release.artifacts entries nfpm packages. v2.48.0 was released 2026-10-12; the sums are its checksums.txt's.
45
+ nfpm: nfpm("v2.48.0", {
46
+ "linux/amd64": ["nfpm_2.48.0_Linux_x86_64.tar.gz", "6d7f9a28b2f397934403950fcbba83f598b08d02edbe79a0815b3b4897341750"],
47
+ "linux/arm64": ["nfpm_2.48.0_Linux_arm64.tar.gz", "a9a75213763783b7669719e505474c748c5ad7dc66591a195619deb50f85c2f4"],
48
+ }),
37
49
  };
38
50
  /**
39
51
  * Shell that downloads `pin` for `platform` into `dir`, checks its SHA-256
@@ -51,6 +51,14 @@ export declare function chantPackageSourceTarget(specifier: string, parentPath:
51
51
  * CommonJS hook from source knows not to add a second one.
52
52
  */
53
53
  export declare function ensureTypeScriptLoader(): boolean;
54
+ /**
55
+ * Whether this process can load a TypeScript module such as
56
+ * `chant.config.ts`: always from source, where a loader already runs chant
57
+ * itself, and in the compiled CLI when tsx resolves from chant's install.
58
+ * Nothing is registered; `chant release init` asks before it writes a
59
+ * config it would have to read back.
60
+ */
61
+ export declare function typeScriptLoaderAvailable(): boolean;
54
62
  /**
55
63
  * #3981 — register tsx only when the module about to be imported is not
56
64
  * JavaScript. `pathOrUrl` is the resolved module, a path or a file URL. A
package/dist/ts-loader.js CHANGED
@@ -241,6 +241,25 @@ export function ensureTypeScriptLoader() {
241
241
  state.tsx = true;
242
242
  return true;
243
243
  }
244
+ /**
245
+ * Whether this process can load a TypeScript module such as
246
+ * `chant.config.ts`: always from source, where a loader already runs chant
247
+ * itself, and in the compiled CLI when tsx resolves from chant's install.
248
+ * Nothing is registered; `chant release init` asks before it writes a
249
+ * config it would have to read back.
250
+ */
251
+ export function typeScriptLoaderAvailable() {
252
+ const state = compiledState();
253
+ if (!state || state.tsx)
254
+ return true;
255
+ try {
256
+ nodeModule.createRequire(import.meta.url).resolve("tsx/cjs/api");
257
+ return true;
258
+ }
259
+ catch {
260
+ return false;
261
+ }
262
+ }
244
263
  /**
245
264
  * #3981 — register tsx only when the module about to be imported is not
246
265
  * JavaScript. `pathOrUrl` is the resolved module, a path or a file URL. A