@intentius/chant-lexicon-github 0.124.58 → 0.124.59
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/components/generate-op-waves-pipeline.d.ts.map +1 -1
- package/dist/components/generate-op-waves-pipeline.js +2 -1
- package/dist/integrity.json +2 -2
- package/dist/manifest.json +1 -1
- package/package.json +2 -2
- package/src/components/generate-op-waves-pipeline.test.ts +7 -0
- package/src/components/generate-op-waves-pipeline.ts +2 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"generate-op-waves-pipeline.d.ts","sourceRoot":"","sources":["../../src/components/generate-op-waves-pipeline.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA2EG;AAEH,OAAO,EAaL,KAAK,WAAW,EACjB,MAAM,8BAA8B,CAAC;AAEtC,OAAO,KAAK,EAAE,sBAAsB,EAAE,qBAAqB,EAAE,MAAM,0BAA0B,CAAC;AAmB9F,OAAO,EAAsB,KAAK,mBAAmB,EAAE,MAAM,wBAAwB,CAAC;AAEtF,yFAAyF;AACzF,eAAO,MAAM,cAAc,YAAW,CAAC;AAEvC,oEAAoE;AACpE,wBAAgB,oBAAoB,CAAC,IAAI,EAAE,IAAI,CAAC,WAAW,EAAE,MAAM,CAAC,EAAE,IAAI,EAAE,MAAM,GAAG,MAAM,CAE1F;AAED,4DAA4D;AAC5D,wBAAgB,qBAAqB,CAAC,IAAI,EAAE,IAAI,CAAC,WAAW,EAAE,MAAM,CAAC,EAAE,OAAO,EAAE,MAAM,GAAG,MAAM,CAE9F;AAED,qEAAqE;AACrE,wBAAgB,qBAAqB,CACnC,IAAI,EAAE,WAAW,EACjB,OAAO,EAAE,sBAAsB,EAC/B,OAAO,GAAE;IAAE,KAAK,CAAC,EAAE,QAAQ,GAAG,SAAS,CAAA;CAAO,GAC7C;IAAE,G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4EAA4E;AAC5E,wBAAgB,6BAA6B,CAAC,IAAI,EAAE,WAAW,EAAE,OAAO,EAAE,sBAAsB,GAAG,qBAAqB,CAMvH"}
|
|
@@ -98,7 +98,8 @@ export function buildGithubOpWavesDoc(spec, options, dialect = {}) {
|
|
|
98
98
|
const forge = dialect.forge ?? "github";
|
|
99
99
|
const product = resolveProductWords(options.words ?? {}).product;
|
|
100
100
|
const image = options.image ?? OP_WAVES_IMAGE;
|
|
101
|
-
|
|
101
|
+
// `approvals.preview` reads the merged pull request from the forge, as a pr-review wave does.
|
|
102
|
+
const byReview = spec.approvals?.preview === true || spec.waves.some((w) => w.approval === "pr-review");
|
|
102
103
|
// #4630: a pr-review or pull-request wave gets the plans workflow and its approval status.
|
|
103
104
|
const statusBeforeMerge = opWavesPostsApprovalStatus(spec);
|
|
104
105
|
for (const wave of spec.waves) {
|
package/dist/integrity.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"algorithm": "sha256",
|
|
3
3
|
"artifacts": {
|
|
4
|
-
"manifest.json": "
|
|
4
|
+
"manifest.json": "4066803d139ed6d48a742aaf7871d082dfbd84e20e3b0ce47759310f71ed6bd6",
|
|
5
5
|
"meta.json": "c50e0ef3845c370c3ad2210b8bba455980417c0f818aa6ed46e06d4fb8b1b9f9",
|
|
6
6
|
"types/index.d.ts": "0ead95536e947ddfb98a5acf0ddb88547913b5a53a342df67711c59266f84b3e",
|
|
7
7
|
"rules/deprecated-action-version.ts": "a9ba7cc924ff1c7055110416d8989273690415bfb5e8dcc32dc9431b9351f5ca",
|
|
@@ -78,5 +78,5 @@
|
|
|
78
78
|
"skills/chant-github-patterns.md": "bb3abef289a8fdfcf07d6bb2d7289dcb2f38bc0cb0321ea320b78b45a6f548c0",
|
|
79
79
|
"skills/chant-github-security.md": "aab111cb0871cad30281ce48d7da23663689619351029219e2be019a1a61e394"
|
|
80
80
|
},
|
|
81
|
-
"composite": "
|
|
81
|
+
"composite": "ae39d39910bc91feedb80f2e03a55d960e100010e9afbf71ff3458d0f3491d49"
|
|
82
82
|
}
|
package/dist/manifest.json
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@intentius/chant-lexicon-github",
|
|
3
|
-
"version": "0.124.
|
|
3
|
+
"version": "0.124.59",
|
|
4
4
|
"description": "GitHub Actions lexicon for chant — declarative IaC in TypeScript",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"homepage": "https://intentius.io/chant",
|
|
@@ -61,6 +61,6 @@
|
|
|
61
61
|
"typescript": "^5.9.3"
|
|
62
62
|
},
|
|
63
63
|
"peerDependencies": {
|
|
64
|
-
"@intentius/chant": "^0.124.
|
|
64
|
+
"@intentius/chant": "^0.124.59"
|
|
65
65
|
}
|
|
66
66
|
}
|
|
@@ -60,6 +60,13 @@ describe("generateGithubOpWavesPipeline", () => {
|
|
|
60
60
|
expect(files[0]!.yaml).toMatch(/permissions:\n\s+contents: write\n\s+pull-requests: read/);
|
|
61
61
|
});
|
|
62
62
|
|
|
63
|
+
test("approvals.preview records the head's plans and lets the wave read the merged pull request", () => {
|
|
64
|
+
const { files } = generateGithubOpWavesPipeline({ ...spec, approvals: { preview: true } }, { specFile: "waves.json" });
|
|
65
|
+
expect(files.map((f) => f.name)).toEqual([`${spec.name}.yml`, `${spec.name}-plans.yml`]);
|
|
66
|
+
expect(files[1]!.yaml).toContain("run: chant run wave --spec waves.json --record-plans");
|
|
67
|
+
expect(files[0]!.yaml).toMatch(/permissions:\n\s+contents: write\n\s+pull-requests: read/);
|
|
68
|
+
});
|
|
69
|
+
|
|
63
70
|
test("a wave-level plan and apply, and stage hooks, render the same jobs: chant run wave runs them (#3762)", () => {
|
|
64
71
|
const { plan: _plan, ...rest } = spec;
|
|
65
72
|
const waveLevel: OpWavesSpec = {
|
|
@@ -135,7 +135,8 @@ export function buildGithubOpWavesDoc(
|
|
|
135
135
|
const forge = dialect.forge ?? "github";
|
|
136
136
|
const product = resolveProductWords(options.words ?? {}).product;
|
|
137
137
|
const image = options.image ?? OP_WAVES_IMAGE;
|
|
138
|
-
|
|
138
|
+
// `approvals.preview` reads the merged pull request from the forge, as a pr-review wave does.
|
|
139
|
+
const byReview = spec.approvals?.preview === true || spec.waves.some((w) => w.approval === "pr-review");
|
|
139
140
|
// #4630: a pr-review or pull-request wave gets the plans workflow and its approval status.
|
|
140
141
|
const statusBeforeMerge = opWavesPostsApprovalStatus(spec);
|
|
141
142
|
for (const wave of spec.waves) {
|