staklink 0.3.19 → 0.3.21

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.
@@ -33935,7 +33935,7 @@ var SSEManager = class {
33935
33935
  var sseManager = new SSEManager();
33936
33936
 
33937
33937
  // src/proxy/version.ts
33938
- var VERSION = "0.3.19";
33938
+ var VERSION = "0.3.21";
33939
33939
 
33940
33940
  // node_modules/uuid/dist/esm/stringify.js
33941
33941
  var byteToHex = [];
@@ -34097,7 +34097,9 @@ var path8 = __toESM(require("path"), 1);
34097
34097
  var SYSTEM_SUFFIX = `
34098
34098
  You can ignore the .pod-config directory if you see it, its just config stuff
34099
34099
 
34100
- The actual dev server is being run with pm2... so you can use pm2 logs to see dev logs. Other processes (such as DB) are being run with docker.
34100
+ The actual dev server is being run with pm2... so you can use pm2 logs to see dev logs. Don't try to start the dev server again if its already running in pm2! Other processes (such as DB) are being run with docker.
34101
+
34102
+ Don't try to write summaries or docs in .md file unless specifically asked to! Default to output text response to the user.
34101
34103
  `;
34102
34104
 
34103
34105
  // src/agent/goose.ts
@@ -80366,11 +80368,13 @@ ${lines2.map((line) => "+" + line).join("\n")}`;
80366
80368
  const repos = getReposWithChangedFiles(code);
80367
80369
  const createPR = req.query.pr === "true";
80368
80370
  const shouldCommit = req.query.commit === "true";
80371
+ const autoMerge = req.query.automerge === "true";
80369
80372
  const commits = [];
80370
80373
  const prs = {};
80371
80374
  const branches = {};
80372
80375
  console.log(`=> Commit requested: ${shouldCommit}`);
80373
80376
  console.log(`=> PR creation requested: ${createPR}`);
80377
+ console.log(`=> Auto-merge requested: ${autoMerge}`);
80374
80378
  console.log(
80375
80379
  `=> Git credentials available: ${!!code.git_credentials?.auth_data?.token}`
80376
80380
  );
@@ -80475,9 +80479,11 @@ ${diff.trim()}`);
80475
80479
  );
80476
80480
  await gh.init();
80477
80481
  const existingPR = await gh.findPRByBranch();
80482
+ let prNumber;
80478
80483
  if (existingPR) {
80479
80484
  console.log(`=> PR already exists: ${existingPR.url}`);
80480
80485
  prs[repoName] = existingPR.url;
80486
+ prNumber = existingPR.number;
80481
80487
  } else {
80482
80488
  const pr = await gh.createPR({
80483
80489
  title: r.commit_name || `Changes from ${currentBranch2}`,
@@ -80487,6 +80493,23 @@ ${diff.trim()}`);
80487
80493
  });
80488
80494
  console.log(`=> PR created: ${pr.url}`);
80489
80495
  prs[repoName] = pr.url;
80496
+ prNumber = pr.number;
80497
+ }
80498
+ if (autoMerge) {
80499
+ try {
80500
+ console.log(`=> Enabling auto-merge for PR #${prNumber}...`);
80501
+ await gh.mergePR(prNumber, {
80502
+ auto: true,
80503
+ method: "squash",
80504
+ deleteBranch: true
80505
+ });
80506
+ console.log(`=> Auto-merge enabled for PR #${prNumber}`);
80507
+ } catch (autoMergeError) {
80508
+ console.error(
80509
+ `=> Failed to enable auto-merge for PR #${prNumber}:`,
80510
+ autoMergeError
80511
+ );
80512
+ }
80490
80513
  }
80491
80514
  } catch (prError) {
80492
80515
  console.error(`=> Failed to create PR for ${r.url}:`, prError);
@@ -10905,7 +10905,7 @@ var glob = Object.assign(glob_, {
10905
10905
  glob.glob = glob;
10906
10906
 
10907
10907
  // src/proxy/version.ts
10908
- var VERSION = "0.3.19";
10908
+ var VERSION = "0.3.21";
10909
10909
 
10910
10910
  // src/cli.ts
10911
10911
  var STAKLINK_PROXY = "staklink-proxy";
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "staklink",
3
3
  "displayName": "staklink",
4
4
  "description": "staklink process manager",
5
- "version": "0.3.19",
5
+ "version": "0.3.21",
6
6
  "type": "module",
7
7
  "publisher": "stakwork",
8
8
  "engines": {