@intentius/chant 0.124.29 → 0.124.31
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/cli/handlers/build.d.ts.map +1 -1
- package/dist/cli/handlers/build.js +4 -1
- package/dist/cli/handlers/fan-out.d.ts.map +1 -1
- package/dist/cli/handlers/fan-out.js +27 -5
- package/dist/cli/handlers/pr.d.ts.map +1 -1
- package/dist/cli/main.d.ts.map +1 -1
- package/dist/cli/main.js +64 -0
- package/dist/cli/parse-args.d.ts.map +1 -1
- package/dist/cli/parse-args.js +99 -0
- package/dist/cli/registry.d.ts +35 -1
- package/dist/cli/registry.d.ts.map +1 -1
- package/dist/components/pr-pipeline.d.ts +24 -0
- package/dist/components/pr-pipeline.d.ts.map +1 -1
- package/dist/components/pr-pipeline.js +16 -0
- package/dist/components/pr-run.d.ts +20 -2
- package/dist/components/pr-run.d.ts.map +1 -1
- package/dist/components/pr-run.js +26 -13
- package/dist/components/wave-plan.d.ts +11 -0
- package/dist/components/wave-plan.d.ts.map +1 -1
- package/dist/components/wave-plan.js +26 -0
- package/dist/lifecycle/release-ledger.d.ts +8 -3
- package/dist/lifecycle/release-ledger.d.ts.map +1 -1
- package/dist/lifecycle/release-ledger.js +2 -0
- package/dist/lifecycle/run-ledger.d.ts +1 -1
- package/dist/lifecycle/run-ledger.d.ts.map +1 -1
- package/dist/lifecycle/run-ledger.js +9 -0
- package/dist/op/activities/activity-contracts.d.ts +1 -0
- package/dist/op/activities/activity-contracts.d.ts.map +1 -1
- package/dist/op/activities/activity-contracts.js +1 -0
- package/dist/op/activities/shell.d.ts +6 -0
- package/dist/op/activities/shell.d.ts.map +1 -1
- package/dist/op/activities/shell.js +1 -1
- package/dist/op/local-executor.d.ts +35 -1
- package/dist/op/local-executor.d.ts.map +1 -1
- package/dist/op/local-executor.js +31 -6
- package/dist/op/redact.d.ts +34 -0
- package/dist/op/redact.d.ts.map +1 -0
- package/dist/op/redact.js +94 -0
- package/dist/op/runtime.d.ts +27 -0
- package/dist/op/runtime.d.ts.map +1 -1
- package/dist/op/runtime.js +20 -0
- package/dist/op/step-console.d.ts +2 -0
- package/dist/op/step-console.d.ts.map +1 -1
- package/dist/op/step-console.js +5 -2
- package/dist/pr-forge.d.ts +40 -0
- package/dist/pr-forge.d.ts.map +1 -1
- package/dist/pr-forge.js +56 -6
- package/dist/pr-loop.d.ts +10 -0
- package/dist/pr-loop.d.ts.map +1 -1
- package/dist/pr-loop.js +7 -0
- package/dist/pr-report-url.d.ts +8 -0
- package/dist/pr-report-url.d.ts.map +1 -1
- package/dist/pr-report-url.js +47 -1
- package/dist/run-event-stream.d.ts +2 -2
- package/dist/run-event-stream.d.ts.map +1 -1
- package/dist/run-event-stream.js +2 -2
- package/dist/run-event.d.ts +15 -0
- package/dist/run-event.d.ts.map +1 -1
- package/dist/run-event.js +2 -0
- package/dist/wave-runtime.mjs +171 -171
- package/dist/workspace/ci-green-forge.d.ts +2 -0
- package/dist/workspace/ci-green-forge.d.ts.map +1 -1
- package/dist/workspace/ci-green.d.ts +2 -0
- package/dist/workspace/ci-green.d.ts.map +1 -1
- package/dist/workspace/ci-green.js +4 -2
- package/dist/workspace/ci-run-index.d.ts +96 -0
- package/dist/workspace/ci-run-index.d.ts.map +1 -0
- package/dist/workspace/ci-run-index.js +162 -0
- package/dist/workspace/ci-run-index.schema.json +50 -0
- package/dist/workspace/ci-run.d.ts +299 -0
- package/dist/workspace/ci-run.d.ts.map +1 -0
- package/dist/workspace/ci-run.js +691 -0
- package/dist/workspace/ci-runner-key.d.ts +120 -0
- package/dist/workspace/ci-runner-key.d.ts.map +1 -0
- package/dist/workspace/ci-runner-key.js +217 -0
- package/dist/workspace/ci-secrets.d.ts +65 -0
- package/dist/workspace/ci-secrets.d.ts.map +1 -0
- package/dist/workspace/ci-secrets.js +211 -0
- package/dist/workspace/ci-serve.d.ts +227 -0
- package/dist/workspace/ci-serve.d.ts.map +1 -0
- package/dist/workspace/ci-serve.js +468 -0
- package/dist/workspace/pr-report.schema.json +5 -0
- package/dist/workspace/reason-codes.d.ts +6 -2
- package/dist/workspace/reason-codes.d.ts.map +1 -1
- package/dist/workspace/reason-codes.js +7 -2
- package/dist/workspace/run-event.schema.json +14 -3
- package/dist/workspace/status-stewards.d.ts +2 -0
- package/dist/workspace/status-stewards.d.ts.map +1 -1
- package/dist/workspace/status-stewards.js +1 -0
- package/dist/workspace/status.schema.json +12 -1
- package/dist/workspace/trust/trust-write.d.ts +109 -0
- package/dist/workspace/trust/trust-write.d.ts.map +1 -0
- package/dist/workspace/trust/trust-write.js +320 -0
- package/dist/workspace/trust-write.schema.json +265 -0
- package/package.json +1 -1
- package/src/cli/handlers/build.test.ts +15 -0
- package/src/cli/handlers/build.ts +4 -1
- package/src/cli/handlers/fan-out.test.ts +82 -0
- package/src/cli/handlers/fan-out.ts +34 -5
- package/src/cli/handlers/pr.ts +5 -0
- package/src/cli/main.test.ts +1 -0
- package/src/cli/main.ts +64 -0
- package/src/cli/parse-args.ts +71 -0
- package/src/cli/registry.ts +35 -1
- package/src/components/pr-pipeline.ts +32 -0
- package/src/components/pr-run.test.ts +127 -0
- package/src/components/pr-run.ts +32 -12
- package/src/components/wave-plan.ts +30 -0
- package/src/lifecycle/release-ledger.ts +9 -3
- package/src/lifecycle/run-ledger.ts +7 -1
- package/src/op/activities/activity-contracts.ts +1 -0
- package/src/op/activities/shell.ts +7 -1
- package/src/op/local-executor.ts +58 -7
- package/src/op/redact.ts +93 -0
- package/src/op/runtime.ts +42 -0
- package/src/op/step-console.ts +7 -2
- package/src/pr-forge.test.ts +54 -0
- package/src/pr-forge.ts +92 -6
- package/src/pr-loop.test.ts +13 -1
- package/src/pr-loop.ts +16 -0
- package/src/pr-report-url.ts +53 -1
- package/src/run-event-stream.ts +4 -3
- package/src/run-event.ts +17 -0
- package/src/workspace/ci-green-forge.ts +2 -0
- package/src/workspace/ci-green.ts +6 -2
- package/src/workspace/ci-run-index.schema.json +50 -0
- package/src/workspace/ci-run-index.test.ts +353 -0
- package/src/workspace/ci-run-index.ts +192 -0
- package/src/workspace/ci-run.test.ts +716 -0
- package/src/workspace/ci-run.ts +833 -0
- package/src/workspace/ci-runner-key.test.ts +166 -0
- package/src/workspace/ci-runner-key.ts +250 -0
- package/src/workspace/ci-secrets.test.ts +106 -0
- package/src/workspace/ci-secrets.ts +213 -0
- package/src/workspace/ci-serve.test.ts +367 -0
- package/src/workspace/ci-serve.ts +574 -0
- package/src/workspace/pr-report.schema.json +5 -0
- package/src/workspace/reason-codes.test.ts +2 -0
- package/src/workspace/reason-codes.ts +7 -2
- package/src/workspace/run-event.schema.json +14 -3
- package/src/workspace/status-stewards.ts +3 -0
- package/src/workspace/status.schema.json +12 -1
- package/src/workspace/trust/trust-write.test.ts +179 -0
- package/src/workspace/trust/trust-write.ts +377 -0
- package/src/workspace/trust-write.schema.json +265 -0
|
@@ -0,0 +1,265 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://intentius.io/chant/schemas/workspace/trust-write/v1/trust-write.schema.json",
|
|
4
|
+
"title": "chant workspace trust runner add|remove output",
|
|
5
|
+
"description": "What `chant workspace trust runner add <principal> --key <key>` and `trust runner remove <principal>` print (#3510): the runner entry before and after the write, the digest of .chant/trust.json after it, or the reason it wrote nothing. Each write edits .chant/trust.json in the working tree in place and never commits. Readers ignore fields they do not know; a field is only ever added within a version. The error codes are a closed list, each in the one closed list of `reason-codes.ts`. Contract version 1 of this document is written by chant 0.124.31 and newer.",
|
|
6
|
+
"oneOf": [
|
|
7
|
+
{
|
|
8
|
+
"$ref": "#/$defs/result"
|
|
9
|
+
},
|
|
10
|
+
{
|
|
11
|
+
"$ref": "#/$defs/failure"
|
|
12
|
+
}
|
|
13
|
+
],
|
|
14
|
+
"$defs": {
|
|
15
|
+
"runner": {
|
|
16
|
+
"type": "object",
|
|
17
|
+
"required": [
|
|
18
|
+
"principal",
|
|
19
|
+
"class",
|
|
20
|
+
"key"
|
|
21
|
+
],
|
|
22
|
+
"additionalProperties": false,
|
|
23
|
+
"properties": {
|
|
24
|
+
"principal": {
|
|
25
|
+
"type": "string",
|
|
26
|
+
"minLength": 1
|
|
27
|
+
},
|
|
28
|
+
"class": {
|
|
29
|
+
"enum": [
|
|
30
|
+
"runner",
|
|
31
|
+
"service"
|
|
32
|
+
]
|
|
33
|
+
},
|
|
34
|
+
"key": {
|
|
35
|
+
"type": "string",
|
|
36
|
+
"pattern": "^ssh-ed25519 [A-Za-z0-9+/]+={0,2}$",
|
|
37
|
+
"description": "The runner's public key, as an ssh-ed25519 line with no comment."
|
|
38
|
+
}
|
|
39
|
+
}
|
|
40
|
+
},
|
|
41
|
+
"digest": {
|
|
42
|
+
"type": "string",
|
|
43
|
+
"pattern": "^[0-9a-f]{64}$",
|
|
44
|
+
"description": "A SHA-256 of the file's bytes, in lowercase hex. A file that is not there has the digest of empty text."
|
|
45
|
+
},
|
|
46
|
+
"result": {
|
|
47
|
+
"description": "The entry was written, or would be with --dry-run, or the file already held it (changed false). Exit code 0.",
|
|
48
|
+
"type": "object",
|
|
49
|
+
"required": [
|
|
50
|
+
"$schema",
|
|
51
|
+
"contract",
|
|
52
|
+
"chant",
|
|
53
|
+
"action",
|
|
54
|
+
"name",
|
|
55
|
+
"path",
|
|
56
|
+
"digest",
|
|
57
|
+
"previousDigest",
|
|
58
|
+
"paths",
|
|
59
|
+
"changed",
|
|
60
|
+
"dryRun",
|
|
61
|
+
"previous",
|
|
62
|
+
"entry",
|
|
63
|
+
"runnerRole"
|
|
64
|
+
],
|
|
65
|
+
"properties": {
|
|
66
|
+
"$schema": {
|
|
67
|
+
"const": "https://intentius.io/chant/schemas/workspace/trust-write/v1/trust-write.schema.json"
|
|
68
|
+
},
|
|
69
|
+
"contract": {
|
|
70
|
+
"const": 1
|
|
71
|
+
},
|
|
72
|
+
"chant": {
|
|
73
|
+
"type": "string",
|
|
74
|
+
"description": "The chant that wrote it."
|
|
75
|
+
},
|
|
76
|
+
"action": {
|
|
77
|
+
"enum": [
|
|
78
|
+
"runner add",
|
|
79
|
+
"runner remove"
|
|
80
|
+
]
|
|
81
|
+
},
|
|
82
|
+
"name": {
|
|
83
|
+
"type": "string",
|
|
84
|
+
"description": "The runner's principal."
|
|
85
|
+
},
|
|
86
|
+
"path": {
|
|
87
|
+
"const": ".chant/trust.json",
|
|
88
|
+
"description": "The trust config, relative to the repository root."
|
|
89
|
+
},
|
|
90
|
+
"digest": {
|
|
91
|
+
"$ref": "#/$defs/digest",
|
|
92
|
+
"description": "The file's digest after the write, or as it would be with --dry-run: what the caller passes as --expect to its next trust write."
|
|
93
|
+
},
|
|
94
|
+
"previousDigest": {
|
|
95
|
+
"$ref": "#/$defs/digest",
|
|
96
|
+
"description": "The file's digest before the write."
|
|
97
|
+
},
|
|
98
|
+
"paths": {
|
|
99
|
+
"type": "array",
|
|
100
|
+
"items": {
|
|
101
|
+
"type": "string"
|
|
102
|
+
},
|
|
103
|
+
"description": "The trust config when the write changed it or would with --dry-run; empty when it already held what was given."
|
|
104
|
+
},
|
|
105
|
+
"changed": {
|
|
106
|
+
"type": "boolean",
|
|
107
|
+
"description": "Whether the file changed: paths is not empty."
|
|
108
|
+
},
|
|
109
|
+
"dryRun": {
|
|
110
|
+
"type": "boolean",
|
|
111
|
+
"description": "True when --dry-run was given: nothing was written, and the document says what would have been."
|
|
112
|
+
},
|
|
113
|
+
"previous": {
|
|
114
|
+
"oneOf": [
|
|
115
|
+
{
|
|
116
|
+
"type": "null"
|
|
117
|
+
},
|
|
118
|
+
{
|
|
119
|
+
"$ref": "#/$defs/runner"
|
|
120
|
+
}
|
|
121
|
+
],
|
|
122
|
+
"description": "The principal's runner entry before the write, or null when there was none."
|
|
123
|
+
},
|
|
124
|
+
"entry": {
|
|
125
|
+
"oneOf": [
|
|
126
|
+
{
|
|
127
|
+
"type": "null"
|
|
128
|
+
},
|
|
129
|
+
{
|
|
130
|
+
"$ref": "#/$defs/runner"
|
|
131
|
+
}
|
|
132
|
+
],
|
|
133
|
+
"description": "The principal's runner entry after the write, or null after runner remove."
|
|
134
|
+
},
|
|
135
|
+
"runnerRole": {
|
|
136
|
+
"type": "boolean",
|
|
137
|
+
"description": "Whether the principal holds the runner role after the write. runner add grants it for class runner; runner remove takes it away."
|
|
138
|
+
}
|
|
139
|
+
}
|
|
140
|
+
},
|
|
141
|
+
"failure": {
|
|
142
|
+
"type": "object",
|
|
143
|
+
"description": "Nothing was written. Exit code 1.",
|
|
144
|
+
"required": [
|
|
145
|
+
"$schema",
|
|
146
|
+
"contract",
|
|
147
|
+
"chant",
|
|
148
|
+
"action",
|
|
149
|
+
"name",
|
|
150
|
+
"error"
|
|
151
|
+
],
|
|
152
|
+
"properties": {
|
|
153
|
+
"$schema": {
|
|
154
|
+
"const": "https://intentius.io/chant/schemas/workspace/trust-write/v1/trust-write.schema.json"
|
|
155
|
+
},
|
|
156
|
+
"contract": {
|
|
157
|
+
"const": 1
|
|
158
|
+
},
|
|
159
|
+
"chant": {
|
|
160
|
+
"type": "string"
|
|
161
|
+
},
|
|
162
|
+
"action": {
|
|
163
|
+
"enum": [
|
|
164
|
+
"runner add",
|
|
165
|
+
"runner remove"
|
|
166
|
+
]
|
|
167
|
+
},
|
|
168
|
+
"name": {
|
|
169
|
+
"type": [
|
|
170
|
+
"string",
|
|
171
|
+
"null"
|
|
172
|
+
]
|
|
173
|
+
},
|
|
174
|
+
"error": {
|
|
175
|
+
"type": "object",
|
|
176
|
+
"required": [
|
|
177
|
+
"code",
|
|
178
|
+
"message"
|
|
179
|
+
],
|
|
180
|
+
"properties": {
|
|
181
|
+
"code": {
|
|
182
|
+
"enum": [
|
|
183
|
+
"not-a-git-repository",
|
|
184
|
+
"write-usage-invalid",
|
|
185
|
+
"trust-config-invalid",
|
|
186
|
+
"trust-conflict",
|
|
187
|
+
"runner-key-invalid",
|
|
188
|
+
"runner-key-is-signer",
|
|
189
|
+
"runner-exists",
|
|
190
|
+
"runner-unknown",
|
|
191
|
+
"write-scope-member",
|
|
192
|
+
"write-scope-protected",
|
|
193
|
+
"write-scope-class-unknown",
|
|
194
|
+
"agent-unknown",
|
|
195
|
+
"principal-unidentified",
|
|
196
|
+
"write-lock-timeout",
|
|
197
|
+
"write-lock-not-held"
|
|
198
|
+
]
|
|
199
|
+
},
|
|
200
|
+
"message": {
|
|
201
|
+
"type": "string"
|
|
202
|
+
}
|
|
203
|
+
}
|
|
204
|
+
},
|
|
205
|
+
"conflict": {
|
|
206
|
+
"type": "object",
|
|
207
|
+
"description": "With trust-conflict: the digest --expect named, the one the file has now, and its last chant write when the write journal knows it.",
|
|
208
|
+
"required": [
|
|
209
|
+
"path",
|
|
210
|
+
"expected",
|
|
211
|
+
"digest",
|
|
212
|
+
"lastWrite"
|
|
213
|
+
],
|
|
214
|
+
"properties": {
|
|
215
|
+
"path": {
|
|
216
|
+
"type": "string"
|
|
217
|
+
},
|
|
218
|
+
"expected": {
|
|
219
|
+
"$ref": "#/$defs/digest"
|
|
220
|
+
},
|
|
221
|
+
"digest": {
|
|
222
|
+
"$ref": "#/$defs/digest"
|
|
223
|
+
},
|
|
224
|
+
"lastWrite": {
|
|
225
|
+
"oneOf": [
|
|
226
|
+
{
|
|
227
|
+
"type": "null"
|
|
228
|
+
},
|
|
229
|
+
{
|
|
230
|
+
"type": "object",
|
|
231
|
+
"required": [
|
|
232
|
+
"verb",
|
|
233
|
+
"by",
|
|
234
|
+
"agent",
|
|
235
|
+
"at"
|
|
236
|
+
],
|
|
237
|
+
"properties": {
|
|
238
|
+
"verb": {
|
|
239
|
+
"type": "string"
|
|
240
|
+
},
|
|
241
|
+
"by": {
|
|
242
|
+
"type": [
|
|
243
|
+
"string",
|
|
244
|
+
"null"
|
|
245
|
+
]
|
|
246
|
+
},
|
|
247
|
+
"agent": {
|
|
248
|
+
"type": [
|
|
249
|
+
"string",
|
|
250
|
+
"null"
|
|
251
|
+
]
|
|
252
|
+
},
|
|
253
|
+
"at": {
|
|
254
|
+
"type": "string"
|
|
255
|
+
}
|
|
256
|
+
}
|
|
257
|
+
}
|
|
258
|
+
]
|
|
259
|
+
}
|
|
260
|
+
}
|
|
261
|
+
}
|
|
262
|
+
}
|
|
263
|
+
}
|
|
264
|
+
}
|
|
265
|
+
}
|