@blogic-cz/agent-tools 0.14.23 → 0.14.24

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@blogic-cz/agent-tools",
3
- "version": "0.14.23",
3
+ "version": "0.14.24",
4
4
  "description": "CLI tools for AI coding agent workflows — GitHub, database, Kubernetes, Azure DevOps, logs, sessions, and audit",
5
5
  "keywords": [
6
6
  "agent",
@@ -445,9 +445,12 @@ export const createPR = Effect.fn("pr.createPR")(function* (opts: {
445
445
 
446
446
  if (Option.isSome(existing)) {
447
447
  const pr = existing.value;
448
- yield* gh.runGh(["pr", "edit", String(pr.number), "--title", opts.title, "--body", opts.body]);
449
-
450
- return yield* viewPR(pr.number);
448
+ return yield* editPR({
449
+ pr: pr.number,
450
+ title: opts.title,
451
+ body: opts.body,
452
+ base: null,
453
+ });
451
454
  }
452
455
 
453
456
  const createArgs = [
@@ -647,17 +650,23 @@ export const editPR = Effect.fn("pr.editPR")(function* (opts: {
647
650
  }
648
651
 
649
652
  const gh = yield* GitHubService;
653
+ const repo = yield* gh.getRepoInfo();
650
654
 
651
- const editArgs = ["pr", "edit", String(opts.pr)];
655
+ const editArgs = [
656
+ "api",
657
+ "--method",
658
+ "PATCH",
659
+ `repos/${repo.owner}/${repo.name}/pulls/${opts.pr}`,
660
+ ];
652
661
 
653
662
  if (opts.title) {
654
- editArgs.push("--title", opts.title);
663
+ editArgs.push("-f", `title=${opts.title}`);
655
664
  }
656
665
  if (opts.body) {
657
- editArgs.push("--body", opts.body);
666
+ editArgs.push("-f", `body=${opts.body}`);
658
667
  }
659
668
  if (opts.base) {
660
- editArgs.push("--base", opts.base);
669
+ editArgs.push("-f", `base=${opts.base}`);
661
670
  }
662
671
 
663
672
  yield* gh.runGh(editArgs);