@webpieces/pr-gate 0.4.833 → 0.4.835

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 (49) hide show
  1. package/package.json +3 -3
  2. package/src/scripts/commands/write-review-command.d.ts +2 -1
  3. package/src/scripts/commands/write-review-command.js +2 -5
  4. package/src/scripts/commands/write-review-command.js.map +1 -1
  5. package/src/scripts/commands/write-review-fixes-command.d.ts +2 -1
  6. package/src/scripts/commands/write-review-fixes-command.js +2 -5
  7. package/src/scripts/commands/write-review-fixes-command.js.map +1 -1
  8. package/src/scripts/git-finishUpsertPr.js +7 -10
  9. package/src/scripts/git-finishUpsertPr.js.map +1 -1
  10. package/src/scripts/pr-gate-cli-app.d.ts +38 -0
  11. package/src/scripts/pr-gate-cli-app.js +255 -0
  12. package/src/scripts/pr-gate-cli-app.js.map +1 -0
  13. package/src/scripts/pr-gate-cli-invocation.d.ts +27 -0
  14. package/src/scripts/pr-gate-cli-invocation.js +71 -0
  15. package/src/scripts/pr-gate-cli-invocation.js.map +1 -0
  16. package/src/scripts/wp-await-checks.js +7 -21
  17. package/src/scripts/wp-await-checks.js.map +1 -1
  18. package/src/scripts/wp-await-reviews.js +7 -18
  19. package/src/scripts/wp-await-reviews.js.map +1 -1
  20. package/src/scripts/wp-build.js +7 -31
  21. package/src/scripts/wp-build.js.map +1 -1
  22. package/src/scripts/wp-check-pr.js +7 -10
  23. package/src/scripts/wp-check-pr.js.map +1 -1
  24. package/src/scripts/wp-cleanup.js +7 -18
  25. package/src/scripts/wp-cleanup.js.map +1 -1
  26. package/src/scripts/wp-finish-push-dev.js +7 -14
  27. package/src/scripts/wp-finish-push-dev.js.map +1 -1
  28. package/src/scripts/wp-finish-update.js +7 -10
  29. package/src/scripts/wp-finish-update.js.map +1 -1
  30. package/src/scripts/wp-human-post-pr.js +7 -9
  31. package/src/scripts/wp-human-post-pr.js.map +1 -1
  32. package/src/scripts/wp-land-pr.js +7 -21
  33. package/src/scripts/wp-land-pr.js.map +1 -1
  34. package/src/scripts/wp-push-dev.js +7 -38
  35. package/src/scripts/wp-push-dev.js.map +1 -1
  36. package/src/scripts/wp-review-upsert-pr.js +7 -10
  37. package/src/scripts/wp-review-upsert-pr.js.map +1 -1
  38. package/src/scripts/wp-start-update.js +7 -10
  39. package/src/scripts/wp-start-update.js.map +1 -1
  40. package/src/scripts/wp-start-upsert-pr.js +7 -10
  41. package/src/scripts/wp-start-upsert-pr.js.map +1 -1
  42. package/src/scripts/wp-sync-main.js +7 -10
  43. package/src/scripts/wp-sync-main.js.map +1 -1
  44. package/src/scripts/wp-upsert-hotfix-pr.js +7 -11
  45. package/src/scripts/wp-upsert-hotfix-pr.js.map +1 -1
  46. package/src/scripts/wp-write-review-fixes.js +7 -10
  47. package/src/scripts/wp-write-review-fixes.js.map +1 -1
  48. package/src/scripts/wp-write-review.js +7 -26
  49. package/src/scripts/wp-write-review.js.map +1 -1
@@ -2,15 +2,12 @@
2
2
  "use strict";
3
3
  Object.defineProperty(exports, "__esModule", { value: true });
4
4
  require("reflect-metadata");
5
- const inversify_1 = require("inversify");
6
5
  const rules_config_1 = require("@webpieces/rules-config");
7
- const pr_gate_app_1 = require("./pr-gate-app");
8
- // Composition root: build the container and resolve the app so inversify constructs the whole DAG.
9
- (0, rules_config_1.runMain)(async () => {
10
- // autobind self-binds every @injectable(Singleton) tooling class (replaces the buildProviderModule registry scan)
11
- const container = new inversify_1.Container({ autobind: true });
12
- // Reject `--help`/bogus flags BEFORE the app touches git — an ignored flag must never start the flow.
13
- container.get(rules_config_1.CliArgs).assertNoArgs(new rules_config_1.CliUsage('wp-review-upsert-pr', 'Validate the 3-point merge, build it, extract this branch\'s diff, and brief the reviewer subagents.'));
14
- await container.get(pr_gate_app_1.PrGateApp).reviewUpsertPr();
15
- });
6
+ const inversify_1 = require("inversify");
7
+ const pr_gate_cli_app_1 = require("./pr-gate-cli-app");
8
+ const pr_gate_cli_invocation_1 = require("./pr-gate-cli-invocation");
9
+ const container = new inversify_1.Container({ autobind: true });
10
+ (0, rules_config_1.runMain)(() => container
11
+ .get(pr_gate_cli_app_1.PrGateCliApp)
12
+ .run(container.get(pr_gate_cli_invocation_1.PrGateCliInvocationFactory).fromProcess('wp-review-upsert-pr')));
16
13
  //# sourceMappingURL=wp-review-upsert-pr.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"wp-review-upsert-pr.js","sourceRoot":"","sources":["../../../../../../packages/tooling/pr-gate/src/scripts/wp-review-upsert-pr.ts"],"names":[],"mappings":";;;AACA,4BAA0B;AAC1B,yCAAsC;AACtC,0DAAqE;AACrE,+CAA0C;AAE1C,mGAAmG;AACnG,IAAA,sBAAO,EAAC,KAAK,IAAmB,EAAE;IAC9B,kHAAkH;IAClH,MAAM,SAAS,GAAG,IAAI,qBAAS,CAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC,CAAC;IACpD,sGAAsG;IACtG,SAAS,CAAC,GAAG,CAAC,sBAAO,CAAC,CAAC,YAAY,CAAC,IAAI,uBAAQ,CAC5C,qBAAqB,EACrB,sGAAsG,CACzG,CAAC,CAAC;IACH,MAAM,SAAS,CAAC,GAAG,CAAC,uBAAS,CAAC,CAAC,cAAc,EAAE,CAAC;AACpD,CAAC,CAAC,CAAC","sourcesContent":["#!/usr/bin/env node\nimport 'reflect-metadata';\nimport { Container } from 'inversify';\nimport { runMain, CliArgs, CliUsage } from '@webpieces/rules-config';\nimport { PrGateApp } from './pr-gate-app';\n\n// Composition root: build the container and resolve the app so inversify constructs the whole DAG.\nrunMain(async (): Promise<void> => {\n // autobind self-binds every @injectable(Singleton) tooling class (replaces the buildProviderModule registry scan)\n const container = new Container({ autobind: true });\n // Reject `--help`/bogus flags BEFORE the app touches git — an ignored flag must never start the flow.\n container.get(CliArgs).assertNoArgs(new CliUsage(\n 'wp-review-upsert-pr',\n 'Validate the 3-point merge, build it, extract this branch\\'s diff, and brief the reviewer subagents.',\n ));\n await container.get(PrGateApp).reviewUpsertPr();\n});\n"]}
1
+ {"version":3,"file":"wp-review-upsert-pr.js","sourceRoot":"","sources":["../../../../../../packages/tooling/pr-gate/src/scripts/wp-review-upsert-pr.ts"],"names":[],"mappings":";;;AACA,4BAA0B;AAC1B,0DAAkD;AAClD,yCAAsC;AACtC,uDAAiD;AACjD,qEAAsE;AAEtE,MAAM,SAAS,GAAG,IAAI,qBAAS,CAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC,CAAC;AACpD,IAAA,sBAAO,EACH,GAAkB,EAAE,CAChB,SAAS;KACJ,GAAG,CAAC,8BAAY,CAAC;KACjB,GAAG,CAAC,SAAS,CAAC,GAAG,CAAC,mDAA0B,CAAC,CAAC,WAAW,CAAC,qBAAqB,CAAC,CAAC,CAC7F,CAAC","sourcesContent":["#!/usr/bin/env node\nimport 'reflect-metadata';\nimport { runMain } from '@webpieces/rules-config';\nimport { Container } from 'inversify';\nimport { PrGateCliApp } from './pr-gate-cli-app';\nimport { PrGateCliInvocationFactory } from './pr-gate-cli-invocation';\n\nconst container = new Container({ autobind: true });\nrunMain(\n (): Promise<void> =>\n container\n .get(PrGateCliApp)\n .run(container.get(PrGateCliInvocationFactory).fromProcess('wp-review-upsert-pr')),\n);\n"]}
@@ -2,15 +2,12 @@
2
2
  "use strict";
3
3
  Object.defineProperty(exports, "__esModule", { value: true });
4
4
  require("reflect-metadata");
5
- const inversify_1 = require("inversify");
6
5
  const rules_config_1 = require("@webpieces/rules-config");
7
- const pr_gate_app_1 = require("./pr-gate-app");
8
- // Composition root: build the container and resolve the app so inversify constructs the whole DAG.
9
- (0, rules_config_1.runMain)(async () => {
10
- // autobind self-binds every @injectable(Singleton) tooling class (replaces the buildProviderModule registry scan)
11
- const container = new inversify_1.Container({ autobind: true });
12
- // Reject `--help`/bogus flags BEFORE the app touches git — an ignored flag must never start the flow.
13
- container.get(rules_config_1.CliArgs).assertNoArgs(new rules_config_1.CliUsage('wp-start-update', '3-point squash-update this feature branch from main (no PR).'));
14
- await container.get(pr_gate_app_1.PrGateApp).startUpdate();
15
- });
6
+ const inversify_1 = require("inversify");
7
+ const pr_gate_cli_app_1 = require("./pr-gate-cli-app");
8
+ const pr_gate_cli_invocation_1 = require("./pr-gate-cli-invocation");
9
+ const container = new inversify_1.Container({ autobind: true });
10
+ (0, rules_config_1.runMain)(() => container
11
+ .get(pr_gate_cli_app_1.PrGateCliApp)
12
+ .run(container.get(pr_gate_cli_invocation_1.PrGateCliInvocationFactory).fromProcess('wp-start-update')));
16
13
  //# sourceMappingURL=wp-start-update.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"wp-start-update.js","sourceRoot":"","sources":["../../../../../../packages/tooling/pr-gate/src/scripts/wp-start-update.ts"],"names":[],"mappings":";;;AACA,4BAA0B;AAC1B,yCAAsC;AACtC,0DAAqE;AACrE,+CAA0C;AAE1C,mGAAmG;AACnG,IAAA,sBAAO,EAAC,KAAK,IAAmB,EAAE;IAC9B,kHAAkH;IAClH,MAAM,SAAS,GAAG,IAAI,qBAAS,CAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC,CAAC;IACpD,sGAAsG;IACtG,SAAS,CAAC,GAAG,CAAC,sBAAO,CAAC,CAAC,YAAY,CAAC,IAAI,uBAAQ,CAAC,iBAAiB,EAAE,8DAA8D,CAAC,CAAC,CAAC;IACrI,MAAM,SAAS,CAAC,GAAG,CAAC,uBAAS,CAAC,CAAC,WAAW,EAAE,CAAC;AACjD,CAAC,CAAC,CAAC","sourcesContent":["#!/usr/bin/env node\nimport 'reflect-metadata';\nimport { Container } from 'inversify';\nimport { runMain, CliArgs, CliUsage } from '@webpieces/rules-config';\nimport { PrGateApp } from './pr-gate-app';\n\n// Composition root: build the container and resolve the app so inversify constructs the whole DAG.\nrunMain(async (): Promise<void> => {\n // autobind self-binds every @injectable(Singleton) tooling class (replaces the buildProviderModule registry scan)\n const container = new Container({ autobind: true });\n // Reject `--help`/bogus flags BEFORE the app touches git — an ignored flag must never start the flow.\n container.get(CliArgs).assertNoArgs(new CliUsage('wp-start-update', '3-point squash-update this feature branch from main (no PR).'));\n await container.get(PrGateApp).startUpdate();\n});\n"]}
1
+ {"version":3,"file":"wp-start-update.js","sourceRoot":"","sources":["../../../../../../packages/tooling/pr-gate/src/scripts/wp-start-update.ts"],"names":[],"mappings":";;;AACA,4BAA0B;AAC1B,0DAAkD;AAClD,yCAAsC;AACtC,uDAAiD;AACjD,qEAAsE;AAEtE,MAAM,SAAS,GAAG,IAAI,qBAAS,CAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC,CAAC;AACpD,IAAA,sBAAO,EACH,GAAkB,EAAE,CAChB,SAAS;KACJ,GAAG,CAAC,8BAAY,CAAC;KACjB,GAAG,CAAC,SAAS,CAAC,GAAG,CAAC,mDAA0B,CAAC,CAAC,WAAW,CAAC,iBAAiB,CAAC,CAAC,CACzF,CAAC","sourcesContent":["#!/usr/bin/env node\nimport 'reflect-metadata';\nimport { runMain } from '@webpieces/rules-config';\nimport { Container } from 'inversify';\nimport { PrGateCliApp } from './pr-gate-cli-app';\nimport { PrGateCliInvocationFactory } from './pr-gate-cli-invocation';\n\nconst container = new Container({ autobind: true });\nrunMain(\n (): Promise<void> =>\n container\n .get(PrGateCliApp)\n .run(container.get(PrGateCliInvocationFactory).fromProcess('wp-start-update')),\n);\n"]}
@@ -2,15 +2,12 @@
2
2
  "use strict";
3
3
  Object.defineProperty(exports, "__esModule", { value: true });
4
4
  require("reflect-metadata");
5
- const inversify_1 = require("inversify");
6
5
  const rules_config_1 = require("@webpieces/rules-config");
7
- const pr_gate_app_1 = require("./pr-gate-app");
8
- // Composition root: build the container and resolve the app so inversify constructs the whole DAG.
9
- (0, rules_config_1.runMain)(async () => {
10
- // autobind self-binds every @injectable(Singleton) tooling class (replaces the buildProviderModule registry scan)
11
- const container = new inversify_1.Container({ autobind: true });
12
- // Reject `--help`/bogus flags BEFORE the app touches git — an ignored flag must never start the flow.
13
- container.get(rules_config_1.CliArgs).assertNoArgs(new rules_config_1.CliUsage('wp-start-upsert-pr', 'Update from main, push, run the build gate, then hand off summary.json.'));
14
- await container.get(pr_gate_app_1.PrGateApp).startUpsertPr();
15
- });
6
+ const inversify_1 = require("inversify");
7
+ const pr_gate_cli_app_1 = require("./pr-gate-cli-app");
8
+ const pr_gate_cli_invocation_1 = require("./pr-gate-cli-invocation");
9
+ const container = new inversify_1.Container({ autobind: true });
10
+ (0, rules_config_1.runMain)(() => container
11
+ .get(pr_gate_cli_app_1.PrGateCliApp)
12
+ .run(container.get(pr_gate_cli_invocation_1.PrGateCliInvocationFactory).fromProcess('wp-start-upsert-pr')));
16
13
  //# sourceMappingURL=wp-start-upsert-pr.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"wp-start-upsert-pr.js","sourceRoot":"","sources":["../../../../../../packages/tooling/pr-gate/src/scripts/wp-start-upsert-pr.ts"],"names":[],"mappings":";;;AACA,4BAA0B;AAC1B,yCAAsC;AACtC,0DAAqE;AACrE,+CAA0C;AAE1C,mGAAmG;AACnG,IAAA,sBAAO,EAAC,KAAK,IAAmB,EAAE;IAC9B,kHAAkH;IAClH,MAAM,SAAS,GAAG,IAAI,qBAAS,CAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC,CAAC;IACpD,sGAAsG;IACtG,SAAS,CAAC,GAAG,CAAC,sBAAO,CAAC,CAAC,YAAY,CAAC,IAAI,uBAAQ,CAAC,oBAAoB,EAAE,yEAAyE,CAAC,CAAC,CAAC;IACnJ,MAAM,SAAS,CAAC,GAAG,CAAC,uBAAS,CAAC,CAAC,aAAa,EAAE,CAAC;AACnD,CAAC,CAAC,CAAC","sourcesContent":["#!/usr/bin/env node\nimport 'reflect-metadata';\nimport { Container } from 'inversify';\nimport { runMain, CliArgs, CliUsage } from '@webpieces/rules-config';\nimport { PrGateApp } from './pr-gate-app';\n\n// Composition root: build the container and resolve the app so inversify constructs the whole DAG.\nrunMain(async (): Promise<void> => {\n // autobind self-binds every @injectable(Singleton) tooling class (replaces the buildProviderModule registry scan)\n const container = new Container({ autobind: true });\n // Reject `--help`/bogus flags BEFORE the app touches git — an ignored flag must never start the flow.\n container.get(CliArgs).assertNoArgs(new CliUsage('wp-start-upsert-pr', 'Update from main, push, run the build gate, then hand off summary.json.'));\n await container.get(PrGateApp).startUpsertPr();\n});\n"]}
1
+ {"version":3,"file":"wp-start-upsert-pr.js","sourceRoot":"","sources":["../../../../../../packages/tooling/pr-gate/src/scripts/wp-start-upsert-pr.ts"],"names":[],"mappings":";;;AACA,4BAA0B;AAC1B,0DAAkD;AAClD,yCAAsC;AACtC,uDAAiD;AACjD,qEAAsE;AAEtE,MAAM,SAAS,GAAG,IAAI,qBAAS,CAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC,CAAC;AACpD,IAAA,sBAAO,EACH,GAAkB,EAAE,CAChB,SAAS;KACJ,GAAG,CAAC,8BAAY,CAAC;KACjB,GAAG,CAAC,SAAS,CAAC,GAAG,CAAC,mDAA0B,CAAC,CAAC,WAAW,CAAC,oBAAoB,CAAC,CAAC,CAC5F,CAAC","sourcesContent":["#!/usr/bin/env node\nimport 'reflect-metadata';\nimport { runMain } from '@webpieces/rules-config';\nimport { Container } from 'inversify';\nimport { PrGateCliApp } from './pr-gate-cli-app';\nimport { PrGateCliInvocationFactory } from './pr-gate-cli-invocation';\n\nconst container = new Container({ autobind: true });\nrunMain(\n (): Promise<void> =>\n container\n .get(PrGateCliApp)\n .run(container.get(PrGateCliInvocationFactory).fromProcess('wp-start-upsert-pr')),\n);\n"]}
@@ -2,15 +2,12 @@
2
2
  "use strict";
3
3
  Object.defineProperty(exports, "__esModule", { value: true });
4
4
  require("reflect-metadata");
5
- const inversify_1 = require("inversify");
6
5
  const rules_config_1 = require("@webpieces/rules-config");
7
- const pr_gate_app_1 = require("./pr-gate-app");
8
- // Composition root: build the container and resolve the app so inversify constructs the whole DAG.
9
- (0, rules_config_1.runMain)(async () => {
10
- // autobind self-binds every @injectable(Singleton) tooling class (replaces the buildProviderModule registry scan)
11
- const container = new inversify_1.Container({ autobind: true });
12
- // Reject `--help`/bogus flags BEFORE the app touches git — an ignored flag must never start the flow.
13
- container.get(rules_config_1.CliArgs).assertNoArgs(new rules_config_1.CliUsage('wp-sync-main', 'Go to main, fast-forward it, reap dead worktrees and branches, and sweep orphan directories.'));
14
- await container.get(pr_gate_app_1.PrGateApp).syncMain();
15
- });
6
+ const inversify_1 = require("inversify");
7
+ const pr_gate_cli_app_1 = require("./pr-gate-cli-app");
8
+ const pr_gate_cli_invocation_1 = require("./pr-gate-cli-invocation");
9
+ const container = new inversify_1.Container({ autobind: true });
10
+ (0, rules_config_1.runMain)(() => container
11
+ .get(pr_gate_cli_app_1.PrGateCliApp)
12
+ .run(container.get(pr_gate_cli_invocation_1.PrGateCliInvocationFactory).fromProcess('wp-sync-main')));
16
13
  //# sourceMappingURL=wp-sync-main.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"wp-sync-main.js","sourceRoot":"","sources":["../../../../../../packages/tooling/pr-gate/src/scripts/wp-sync-main.ts"],"names":[],"mappings":";;;AACA,4BAA0B;AAC1B,yCAAsC;AACtC,0DAAqE;AACrE,+CAA0C;AAE1C,mGAAmG;AACnG,IAAA,sBAAO,EAAC,KAAK,IAAmB,EAAE;IAC9B,kHAAkH;IAClH,MAAM,SAAS,GAAG,IAAI,qBAAS,CAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC,CAAC;IACpD,sGAAsG;IACtG,SAAS,CAAC,GAAG,CAAC,sBAAO,CAAC,CAAC,YAAY,CAAC,IAAI,uBAAQ,CAC5C,cAAc,EACd,8FAA8F,CAAC,CAAC,CAAC;IACrG,MAAM,SAAS,CAAC,GAAG,CAAC,uBAAS,CAAC,CAAC,QAAQ,EAAE,CAAC;AAC9C,CAAC,CAAC,CAAC","sourcesContent":["#!/usr/bin/env node\nimport 'reflect-metadata';\nimport { Container } from 'inversify';\nimport { runMain, CliArgs, CliUsage } from '@webpieces/rules-config';\nimport { PrGateApp } from './pr-gate-app';\n\n// Composition root: build the container and resolve the app so inversify constructs the whole DAG.\nrunMain(async (): Promise<void> => {\n // autobind self-binds every @injectable(Singleton) tooling class (replaces the buildProviderModule registry scan)\n const container = new Container({ autobind: true });\n // Reject `--help`/bogus flags BEFORE the app touches git — an ignored flag must never start the flow.\n container.get(CliArgs).assertNoArgs(new CliUsage(\n 'wp-sync-main',\n 'Go to main, fast-forward it, reap dead worktrees and branches, and sweep orphan directories.'));\n await container.get(PrGateApp).syncMain();\n});\n"]}
1
+ {"version":3,"file":"wp-sync-main.js","sourceRoot":"","sources":["../../../../../../packages/tooling/pr-gate/src/scripts/wp-sync-main.ts"],"names":[],"mappings":";;;AACA,4BAA0B;AAC1B,0DAAkD;AAClD,yCAAsC;AACtC,uDAAiD;AACjD,qEAAsE;AAEtE,MAAM,SAAS,GAAG,IAAI,qBAAS,CAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC,CAAC;AACpD,IAAA,sBAAO,EACH,GAAkB,EAAE,CAChB,SAAS;KACJ,GAAG,CAAC,8BAAY,CAAC;KACjB,GAAG,CAAC,SAAS,CAAC,GAAG,CAAC,mDAA0B,CAAC,CAAC,WAAW,CAAC,cAAc,CAAC,CAAC,CACtF,CAAC","sourcesContent":["#!/usr/bin/env node\nimport 'reflect-metadata';\nimport { runMain } from '@webpieces/rules-config';\nimport { Container } from 'inversify';\nimport { PrGateCliApp } from './pr-gate-cli-app';\nimport { PrGateCliInvocationFactory } from './pr-gate-cli-invocation';\n\nconst container = new Container({ autobind: true });\nrunMain(\n (): Promise<void> =>\n container\n .get(PrGateCliApp)\n .run(container.get(PrGateCliInvocationFactory).fromProcess('wp-sync-main')),\n);\n"]}
@@ -2,16 +2,12 @@
2
2
  "use strict";
3
3
  Object.defineProperty(exports, "__esModule", { value: true });
4
4
  require("reflect-metadata");
5
- const inversify_1 = require("inversify");
6
5
  const rules_config_1 = require("@webpieces/rules-config");
7
- const pr_gate_app_1 = require("./pr-gate-app");
8
- // Composition root for `wp-upsert-hotfix-pr` (issue #1057): publish a /hotfix/ branch in one command.
9
- (0, rules_config_1.runMain)(async () => {
10
- const container = new inversify_1.Container({ autobind: true });
11
- container
12
- .get(rules_config_1.CliArgs)
13
- .assertNoArgs(new rules_config_1.CliUsage('wp-upsert-hotfix-pr', 'Publish the current /hotfix/ branch: hotfix-ci gate (build + test), no merge from main, one\n' +
14
- 'fast-forward push, then create or update the audit-bannered PR to main. Never auto-merges.'));
15
- await container.get(pr_gate_app_1.PrGateApp).upsertHotfixPr();
16
- });
6
+ const inversify_1 = require("inversify");
7
+ const pr_gate_cli_app_1 = require("./pr-gate-cli-app");
8
+ const pr_gate_cli_invocation_1 = require("./pr-gate-cli-invocation");
9
+ const container = new inversify_1.Container({ autobind: true });
10
+ (0, rules_config_1.runMain)(() => container
11
+ .get(pr_gate_cli_app_1.PrGateCliApp)
12
+ .run(container.get(pr_gate_cli_invocation_1.PrGateCliInvocationFactory).fromProcess('wp-upsert-hotfix-pr')));
17
13
  //# sourceMappingURL=wp-upsert-hotfix-pr.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"wp-upsert-hotfix-pr.js","sourceRoot":"","sources":["../../../../../../packages/tooling/pr-gate/src/scripts/wp-upsert-hotfix-pr.ts"],"names":[],"mappings":";;;AACA,4BAA0B;AAC1B,yCAAsC;AACtC,0DAAqE;AACrE,+CAA0C;AAE1C,sGAAsG;AACtG,IAAA,sBAAO,EAAC,KAAK,IAAmB,EAAE;IAC9B,MAAM,SAAS,GAAG,IAAI,qBAAS,CAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC,CAAC;IACpD,SAAS;SACJ,GAAG,CAAC,sBAAO,CAAC;SACZ,YAAY,CACT,IAAI,uBAAQ,CACR,qBAAqB,EACrB,+FAA+F;QAC3F,4FAA4F,CACnG,CACJ,CAAC;IACN,MAAM,SAAS,CAAC,GAAG,CAAC,uBAAS,CAAC,CAAC,cAAc,EAAE,CAAC;AACpD,CAAC,CAAC,CAAC","sourcesContent":["#!/usr/bin/env node\nimport 'reflect-metadata';\nimport { Container } from 'inversify';\nimport { CliArgs, CliUsage, runMain } from '@webpieces/rules-config';\nimport { PrGateApp } from './pr-gate-app';\n\n// Composition root for `wp-upsert-hotfix-pr` (issue #1057): publish a /hotfix/ branch in one command.\nrunMain(async (): Promise<void> => {\n const container = new Container({ autobind: true });\n container\n .get(CliArgs)\n .assertNoArgs(\n new CliUsage(\n 'wp-upsert-hotfix-pr',\n 'Publish the current /hotfix/ branch: hotfix-ci gate (build + test), no merge from main, one\\n' +\n 'fast-forward push, then create or update the audit-bannered PR to main. Never auto-merges.',\n ),\n );\n await container.get(PrGateApp).upsertHotfixPr();\n});\n"]}
1
+ {"version":3,"file":"wp-upsert-hotfix-pr.js","sourceRoot":"","sources":["../../../../../../packages/tooling/pr-gate/src/scripts/wp-upsert-hotfix-pr.ts"],"names":[],"mappings":";;;AACA,4BAA0B;AAC1B,0DAAkD;AAClD,yCAAsC;AACtC,uDAAiD;AACjD,qEAAsE;AAEtE,MAAM,SAAS,GAAG,IAAI,qBAAS,CAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC,CAAC;AACpD,IAAA,sBAAO,EACH,GAAkB,EAAE,CAChB,SAAS;KACJ,GAAG,CAAC,8BAAY,CAAC;KACjB,GAAG,CAAC,SAAS,CAAC,GAAG,CAAC,mDAA0B,CAAC,CAAC,WAAW,CAAC,qBAAqB,CAAC,CAAC,CAC7F,CAAC","sourcesContent":["#!/usr/bin/env node\nimport 'reflect-metadata';\nimport { runMain } from '@webpieces/rules-config';\nimport { Container } from 'inversify';\nimport { PrGateCliApp } from './pr-gate-cli-app';\nimport { PrGateCliInvocationFactory } from './pr-gate-cli-invocation';\n\nconst container = new Container({ autobind: true });\nrunMain(\n (): Promise<void> =>\n container\n .get(PrGateCliApp)\n .run(container.get(PrGateCliInvocationFactory).fromProcess('wp-upsert-hotfix-pr')),\n);\n"]}
@@ -2,15 +2,12 @@
2
2
  "use strict";
3
3
  Object.defineProperty(exports, "__esModule", { value: true });
4
4
  require("reflect-metadata");
5
- const inversify_1 = require("inversify");
6
5
  const rules_config_1 = require("@webpieces/rules-config");
7
- const pr_gate_app_1 = require("./pr-gate-app");
8
- const write_review_fixes_command_1 = require("./commands/write-review-fixes-command");
9
- const FILE = '--file';
10
- (0, rules_config_1.runMain)(async () => {
11
- const container = new inversify_1.Container({ autobind: true });
12
- const args = container.get(rules_config_1.CliArgs).parse(new rules_config_1.CliUsage('wp-write-review-fixes', 'Record the coordinating agent response to every red finding in the completed reviewer round.', [new rules_config_1.CliFlag(FILE, 'JSON file. Omit to pass JSON on stdin.', true)]));
13
- const json = container.get(write_review_fixes_command_1.WriteReviewFixesInput).read(args.value(FILE));
14
- await container.get(pr_gate_app_1.PrGateApp).writeReviewFixes(new write_review_fixes_command_1.WriteReviewFixesOptions(json, process.cwd()));
15
- });
6
+ const inversify_1 = require("inversify");
7
+ const pr_gate_cli_app_1 = require("./pr-gate-cli-app");
8
+ const pr_gate_cli_invocation_1 = require("./pr-gate-cli-invocation");
9
+ const container = new inversify_1.Container({ autobind: true });
10
+ (0, rules_config_1.runMain)(() => container
11
+ .get(pr_gate_cli_app_1.PrGateCliApp)
12
+ .run(container.get(pr_gate_cli_invocation_1.PrGateCliInvocationFactory).fromProcess('wp-write-review-fixes')));
16
13
  //# sourceMappingURL=wp-write-review-fixes.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"wp-write-review-fixes.js","sourceRoot":"","sources":["../../../../../../packages/tooling/pr-gate/src/scripts/wp-write-review-fixes.ts"],"names":[],"mappings":";;;AACA,4BAA0B;AAC1B,yCAAsC;AACtC,0DAA8E;AAC9E,+CAA0C;AAC1C,sFAAuG;AAEvG,MAAM,IAAI,GAAG,QAAQ,CAAC;AAEtB,IAAA,sBAAO,EAAC,KAAK,IAAmB,EAAE;IAC9B,MAAM,SAAS,GAAG,IAAI,qBAAS,CAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC,CAAC;IACpD,MAAM,IAAI,GAAG,SAAS,CAAC,GAAG,CAAC,sBAAO,CAAC,CAAC,KAAK,CAAC,IAAI,uBAAQ,CAClD,uBAAuB,EACvB,8FAA8F,EAC9F,CAAC,IAAI,sBAAO,CAAC,IAAI,EAAE,wCAAwC,EAAE,IAAI,CAAC,CAAC,CAAC,CAAC,CAAC;IAC1E,MAAM,IAAI,GAAG,SAAS,CAAC,GAAG,CAAC,kDAAqB,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,CAAC,CAAC;IACzE,MAAM,SAAS,CAAC,GAAG,CAAC,uBAAS,CAAC,CAAC,gBAAgB,CAAC,IAAI,oDAAuB,CAAC,IAAI,EAAE,OAAO,CAAC,GAAG,EAAE,CAAC,CAAC,CAAC;AACtG,CAAC,CAAC,CAAC","sourcesContent":["#!/usr/bin/env node\nimport 'reflect-metadata';\nimport { Container } from 'inversify';\nimport { CliArgs, CliFlag, CliUsage, runMain } from '@webpieces/rules-config';\nimport { PrGateApp } from './pr-gate-app';\nimport { WriteReviewFixesInput, WriteReviewFixesOptions } from './commands/write-review-fixes-command';\n\nconst FILE = '--file';\n\nrunMain(async (): Promise<void> => {\n const container = new Container({ autobind: true });\n const args = container.get(CliArgs).parse(new CliUsage(\n 'wp-write-review-fixes',\n 'Record the coordinating agent response to every red finding in the completed reviewer round.',\n [new CliFlag(FILE, 'JSON file. Omit to pass JSON on stdin.', true)]));\n const json = container.get(WriteReviewFixesInput).read(args.value(FILE));\n await container.get(PrGateApp).writeReviewFixes(new WriteReviewFixesOptions(json, process.cwd()));\n});\n"]}
1
+ {"version":3,"file":"wp-write-review-fixes.js","sourceRoot":"","sources":["../../../../../../packages/tooling/pr-gate/src/scripts/wp-write-review-fixes.ts"],"names":[],"mappings":";;;AACA,4BAA0B;AAC1B,0DAAkD;AAClD,yCAAsC;AACtC,uDAAiD;AACjD,qEAAsE;AAEtE,MAAM,SAAS,GAAG,IAAI,qBAAS,CAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC,CAAC;AACpD,IAAA,sBAAO,EACH,GAAkB,EAAE,CAChB,SAAS;KACJ,GAAG,CAAC,8BAAY,CAAC;KACjB,GAAG,CAAC,SAAS,CAAC,GAAG,CAAC,mDAA0B,CAAC,CAAC,WAAW,CAAC,uBAAuB,CAAC,CAAC,CAC/F,CAAC","sourcesContent":["#!/usr/bin/env node\nimport 'reflect-metadata';\nimport { runMain } from '@webpieces/rules-config';\nimport { Container } from 'inversify';\nimport { PrGateCliApp } from './pr-gate-cli-app';\nimport { PrGateCliInvocationFactory } from './pr-gate-cli-invocation';\n\nconst container = new Container({ autobind: true });\nrunMain(\n (): Promise<void> =>\n container\n .get(PrGateCliApp)\n .run(container.get(PrGateCliInvocationFactory).fromProcess('wp-write-review-fixes')),\n);\n"]}
@@ -2,31 +2,12 @@
2
2
  "use strict";
3
3
  Object.defineProperty(exports, "__esModule", { value: true });
4
4
  require("reflect-metadata");
5
- const inversify_1 = require("inversify");
6
5
  const rules_config_1 = require("@webpieces/rules-config");
7
- const pr_gate_app_1 = require("./pr-gate-app");
8
- const write_review_command_1 = require("./commands/write-review-command");
9
- const CHECKLIST = '--checklist';
10
- const FILE = '--file';
11
- const CHECK = '--check';
12
- // Composition root for `wp-write-review`: the ONE way a reviewer subagent submits a checklist verdict
13
- // (issue #863). The command an agent types stays PLAIN — `pnpm wp-write-review --checklist <id>` with the
14
- // JSON on stdin — because the PreToolUse hook reads that literal command to stamp WHO is running it, and a
15
- // worktree-isolated subagent's harness only runs commands it can see stay inside the worktree.
16
- (0, rules_config_1.runMain)(async () => {
17
- const container = new inversify_1.Container({ autobind: true });
18
- const args = container.get(rules_config_1.CliArgs).parse(new rules_config_1.CliUsage('wp-write-review', 'Submit ONE reviewer verdict for ONE checklist. Reviewer subagents only — the coordinating agent is refused.', [
19
- new rules_config_1.CliFlag(CHECKLIST, 'REQUIRED. The checklist id your instructions file names, e.g. --checklist security.', true),
20
- new rules_config_1.CliFlag(FILE, 'The verdict JSON file. Omit it to pass the JSON on stdin:\n'
21
- + " pnpm wp-write-review --checklist <id> <<'EOF' … EOF", true),
22
- new rules_config_1.CliFlag(CHECK, 'Submit nothing: only say whether this checklist may still be reviewed on this branch. A reviewer\n'
23
- + ' runs it FIRST; it refuses once the checklist was reviewed maxReviewerRounds times.'),
24
- ]));
25
- if (args.has(CHECK)) {
26
- await container.get(pr_gate_app_1.PrGateApp).checkReviewBudget(new write_review_command_1.ReviewBudgetCheckOptions(args.value(CHECKLIST), process.cwd()));
27
- return;
28
- }
29
- const json = container.get(write_review_command_1.WriteReviewInput).read(args.value(FILE));
30
- await container.get(pr_gate_app_1.PrGateApp).writeReview(new write_review_command_1.WriteReviewOptions(args.value(CHECKLIST), json, process.cwd()));
31
- });
6
+ const inversify_1 = require("inversify");
7
+ const pr_gate_cli_app_1 = require("./pr-gate-cli-app");
8
+ const pr_gate_cli_invocation_1 = require("./pr-gate-cli-invocation");
9
+ const container = new inversify_1.Container({ autobind: true });
10
+ (0, rules_config_1.runMain)(() => container
11
+ .get(pr_gate_cli_app_1.PrGateCliApp)
12
+ .run(container.get(pr_gate_cli_invocation_1.PrGateCliInvocationFactory).fromProcess('wp-write-review')));
32
13
  //# sourceMappingURL=wp-write-review.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"wp-write-review.js","sourceRoot":"","sources":["../../../../../../packages/tooling/pr-gate/src/scripts/wp-write-review.ts"],"names":[],"mappings":";;;AACA,4BAA0B;AAC1B,yCAAsC;AACtC,0DAA8E;AAC9E,+CAA0C;AAC1C,0EAAiH;AAEjH,MAAM,SAAS,GAAG,aAAa,CAAC;AAChC,MAAM,IAAI,GAAG,QAAQ,CAAC;AACtB,MAAM,KAAK,GAAG,SAAS,CAAC;AAExB,sGAAsG;AACtG,0GAA0G;AAC1G,2GAA2G;AAC3G,+FAA+F;AAC/F,IAAA,sBAAO,EAAC,KAAK,IAAmB,EAAE;IAC9B,MAAM,SAAS,GAAG,IAAI,qBAAS,CAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC,CAAC;IACpD,MAAM,IAAI,GAAG,SAAS,CAAC,GAAG,CAAC,sBAAO,CAAC,CAAC,KAAK,CAAC,IAAI,uBAAQ,CAClD,iBAAiB,EACjB,6GAA6G,EAC7G;QACI,IAAI,sBAAO,CAAC,SAAS,EAAE,qFAAqF,EAAE,IAAI,CAAC;QACnH,IAAI,sBAAO,CAAC,IAAI,EACZ,6DAA6D;cAC3D,qEAAqE,EAAE,IAAI,CAAC;QAClF,IAAI,sBAAO,CAAC,KAAK,EACb,oGAAoG;cAClG,oGAAoG,CAAC;KAC9G,CAAC,CAAC,CAAC;IACR,IAAI,IAAI,CAAC,GAAG,CAAC,KAAK,CAAC,EAAE,CAAC;QAClB,MAAM,SAAS,CAAC,GAAG,CAAC,uBAAS,CAAC,CAAC,iBAAiB,CAAC,IAAI,+CAAwB,CAAC,IAAI,CAAC,KAAK,CAAC,SAAS,CAAC,EAAE,OAAO,CAAC,GAAG,EAAE,CAAC,CAAC,CAAC;QACrH,OAAO;IACX,CAAC;IACD,MAAM,IAAI,GAAG,SAAS,CAAC,GAAG,CAAC,uCAAgB,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,CAAC,CAAC;IACpE,MAAM,SAAS,CAAC,GAAG,CAAC,uBAAS,CAAC,CAAC,WAAW,CAAC,IAAI,yCAAkB,CAAC,IAAI,CAAC,KAAK,CAAC,SAAS,CAAC,EAAE,IAAI,EAAE,OAAO,CAAC,GAAG,EAAE,CAAC,CAAC,CAAC;AACnH,CAAC,CAAC,CAAC","sourcesContent":["#!/usr/bin/env node\nimport 'reflect-metadata';\nimport { Container } from 'inversify';\nimport { runMain, CliArgs, CliFlag, CliUsage } from '@webpieces/rules-config';\nimport { PrGateApp } from './pr-gate-app';\nimport { ReviewBudgetCheckOptions, WriteReviewInput, WriteReviewOptions } from './commands/write-review-command';\n\nconst CHECKLIST = '--checklist';\nconst FILE = '--file';\nconst CHECK = '--check';\n\n// Composition root for `wp-write-review`: the ONE way a reviewer subagent submits a checklist verdict\n// (issue #863). The command an agent types stays PLAIN — `pnpm wp-write-review --checklist <id>` with the\n// JSON on stdin — because the PreToolUse hook reads that literal command to stamp WHO is running it, and a\n// worktree-isolated subagent's harness only runs commands it can see stay inside the worktree.\nrunMain(async (): Promise<void> => {\n const container = new Container({ autobind: true });\n const args = container.get(CliArgs).parse(new CliUsage(\n 'wp-write-review',\n 'Submit ONE reviewer verdict for ONE checklist. Reviewer subagents only — the coordinating agent is refused.',\n [\n new CliFlag(CHECKLIST, 'REQUIRED. The checklist id your instructions file names, e.g. --checklist security.', true),\n new CliFlag(FILE,\n 'The verdict JSON file. Omit it to pass the JSON on stdin:\\n'\n + \" pnpm wp-write-review --checklist <id> <<'EOF' … EOF\", true),\n new CliFlag(CHECK,\n 'Submit nothing: only say whether this checklist may still be reviewed on this branch. A reviewer\\n'\n + ' runs it FIRST; it refuses once the checklist was reviewed maxReviewerRounds times.'),\n ]));\n if (args.has(CHECK)) {\n await container.get(PrGateApp).checkReviewBudget(new ReviewBudgetCheckOptions(args.value(CHECKLIST), process.cwd()));\n return;\n }\n const json = container.get(WriteReviewInput).read(args.value(FILE));\n await container.get(PrGateApp).writeReview(new WriteReviewOptions(args.value(CHECKLIST), json, process.cwd()));\n});\n"]}
1
+ {"version":3,"file":"wp-write-review.js","sourceRoot":"","sources":["../../../../../../packages/tooling/pr-gate/src/scripts/wp-write-review.ts"],"names":[],"mappings":";;;AACA,4BAA0B;AAC1B,0DAAkD;AAClD,yCAAsC;AACtC,uDAAiD;AACjD,qEAAsE;AAEtE,MAAM,SAAS,GAAG,IAAI,qBAAS,CAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC,CAAC;AACpD,IAAA,sBAAO,EACH,GAAkB,EAAE,CAChB,SAAS;KACJ,GAAG,CAAC,8BAAY,CAAC;KACjB,GAAG,CAAC,SAAS,CAAC,GAAG,CAAC,mDAA0B,CAAC,CAAC,WAAW,CAAC,iBAAiB,CAAC,CAAC,CACzF,CAAC","sourcesContent":["#!/usr/bin/env node\nimport 'reflect-metadata';\nimport { runMain } from '@webpieces/rules-config';\nimport { Container } from 'inversify';\nimport { PrGateCliApp } from './pr-gate-cli-app';\nimport { PrGateCliInvocationFactory } from './pr-gate-cli-invocation';\n\nconst container = new Container({ autobind: true });\nrunMain(\n (): Promise<void> =>\n container\n .get(PrGateCliApp)\n .run(container.get(PrGateCliInvocationFactory).fromProcess('wp-write-review')),\n);\n"]}