@iloom/cli 0.9.0 → 0.9.1

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 (52) hide show
  1. package/LICENSE +1 -1
  2. package/README.md +1 -1
  3. package/dist/{GitHubService-ACZVNTJE.js → GitHubService-O7T6CFAJ.js} +3 -3
  4. package/dist/README.md +1 -1
  5. package/dist/{chunk-SC6X5EBG.js → chunk-3P6J4IZZ.js} +3 -3
  6. package/dist/{chunk-6Y3FTRJL.js → chunk-4ZIHFUPN.js} +41 -18
  7. package/dist/chunk-4ZIHFUPN.js.map +1 -0
  8. package/dist/{chunk-RNBIISBZ.js → chunk-ENGCJIYQ.js} +48 -3
  9. package/dist/chunk-ENGCJIYQ.js.map +1 -0
  10. package/dist/{chunk-I23OQB4Y.js → chunk-I3HMNWQQ.js} +6 -5
  11. package/dist/chunk-I3HMNWQQ.js.map +1 -0
  12. package/dist/{chunk-XJHQVOT6.js → chunk-J7FJ6PUT.js} +2 -2
  13. package/dist/{chunk-UDZCTLD6.js → chunk-OK7LUTRW.js} +3 -3
  14. package/dist/{chunk-Z6F5CUS6.js → chunk-POU2UMWN.js} +2 -2
  15. package/dist/{chunk-THS5L54H.js → chunk-TRUMP4DA.js} +26 -2
  16. package/dist/{chunk-THS5L54H.js.map → chunk-TRUMP4DA.js.map} +1 -1
  17. package/dist/{chunk-PVW6JE7E.js → chunk-Y5HSSIK2.js} +2 -2
  18. package/dist/{chunk-PL2FDYEK.js → chunk-Y5O2ALDZ.js} +2 -2
  19. package/dist/{cleanup-M6N7KV7E.js → cleanup-D3CSRBBZ.js} +8 -8
  20. package/dist/cli.js +36 -20
  21. package/dist/cli.js.map +1 -1
  22. package/dist/{commit-ORHR53KW.js → commit-IWGT42XN.js} +4 -4
  23. package/dist/{contribute-4KCEOHSH.js → contribute-WSJTV2RX.js} +2 -2
  24. package/dist/{feedback-XRI7SGYX.js → feedback-QPNDZQRV.js} +5 -5
  25. package/dist/{ignite-3FHQY23X.js → ignite-OPO6EDYT.js} +6 -6
  26. package/dist/index.d.ts +3 -0
  27. package/dist/index.js +3 -2
  28. package/dist/index.js.map +1 -1
  29. package/dist/issues-L7TBUPXT.js +116 -0
  30. package/dist/issues-L7TBUPXT.js.map +1 -0
  31. package/dist/mcp/issue-management-server.js +3 -2
  32. package/dist/mcp/issue-management-server.js.map +1 -1
  33. package/dist/{plan-P6MXL7AU.js → plan-BRJBFJHF.js} +7 -7
  34. package/dist/{summary-WNEYCO4S.js → summary-ZKOA35PT.js} +6 -6
  35. package/package.json +1 -1
  36. package/dist/chunk-6Y3FTRJL.js.map +0 -1
  37. package/dist/chunk-I23OQB4Y.js.map +0 -1
  38. package/dist/chunk-RNBIISBZ.js.map +0 -1
  39. /package/dist/{GitHubService-ACZVNTJE.js.map → GitHubService-O7T6CFAJ.js.map} +0 -0
  40. /package/dist/{chunk-SC6X5EBG.js.map → chunk-3P6J4IZZ.js.map} +0 -0
  41. /package/dist/{chunk-XJHQVOT6.js.map → chunk-J7FJ6PUT.js.map} +0 -0
  42. /package/dist/{chunk-UDZCTLD6.js.map → chunk-OK7LUTRW.js.map} +0 -0
  43. /package/dist/{chunk-Z6F5CUS6.js.map → chunk-POU2UMWN.js.map} +0 -0
  44. /package/dist/{chunk-PVW6JE7E.js.map → chunk-Y5HSSIK2.js.map} +0 -0
  45. /package/dist/{chunk-PL2FDYEK.js.map → chunk-Y5O2ALDZ.js.map} +0 -0
  46. /package/dist/{cleanup-M6N7KV7E.js.map → cleanup-D3CSRBBZ.js.map} +0 -0
  47. /package/dist/{commit-ORHR53KW.js.map → commit-IWGT42XN.js.map} +0 -0
  48. /package/dist/{contribute-4KCEOHSH.js.map → contribute-WSJTV2RX.js.map} +0 -0
  49. /package/dist/{feedback-XRI7SGYX.js.map → feedback-QPNDZQRV.js.map} +0 -0
  50. /package/dist/{ignite-3FHQY23X.js.map → ignite-OPO6EDYT.js.map} +0 -0
  51. /package/dist/{plan-P6MXL7AU.js.map → plan-BRJBFJHF.js.map} +0 -0
  52. /package/dist/{summary-WNEYCO4S.js.map → summary-ZKOA35PT.js.map} +0 -0
package/LICENSE CHANGED
@@ -20,7 +20,7 @@ it within your organization. What is prohibited is redistributing or offering
20
20
  access to this software (in original or modified form) as part of something
21
21
  you sell or provide to others.
22
22
 
23
- Change Date: 2030-02-06
23
+ Change Date: 2030-02-11
24
24
  Change License: Apache License 2.0
25
25
 
26
26
  For clarity, on or after the Change Date, the Licensed Work will
package/README.md CHANGED
@@ -600,7 +600,7 @@ License & Name
600
600
 
601
601
  * ❌ You cannot resell iloom itself as a product or SaaS.
602
602
 
603
- * Converts to Apache 2.0 on 2030-02-06.
603
+ * Converts to Apache 2.0 on 2030-02-11.
604
604
 
605
605
 
606
606
  See [LICENSE](https://raw.githubusercontent.com/iloom-ai/iloom-cli/main/LICENSE) for complete terms.
@@ -1,12 +1,12 @@
1
1
  #!/usr/bin/env node
2
2
  import {
3
3
  GitHubService
4
- } from "./chunk-PVW6JE7E.js";
5
- import "./chunk-THS5L54H.js";
4
+ } from "./chunk-Y5HSSIK2.js";
5
+ import "./chunk-TRUMP4DA.js";
6
6
  import "./chunk-7JDMYTFZ.js";
7
7
  import "./chunk-6MLEBAYZ.js";
8
8
  import "./chunk-VT4PDUYT.js";
9
9
  export {
10
10
  GitHubService
11
11
  };
12
- //# sourceMappingURL=GitHubService-ACZVNTJE.js.map
12
+ //# sourceMappingURL=GitHubService-O7T6CFAJ.js.map
package/dist/README.md CHANGED
@@ -600,7 +600,7 @@ License & Name
600
600
 
601
601
  * ❌ You cannot resell iloom itself as a product or SaaS.
602
602
 
603
- * Converts to Apache 2.0 on 2030-02-06.
603
+ * Converts to Apache 2.0 on 2030-02-11.
604
604
 
605
605
 
606
606
  See [LICENSE](https://raw.githubusercontent.com/iloom-ai/iloom-cli/main/LICENSE) for complete terms.
@@ -4,10 +4,10 @@ import {
4
4
  createLinearIssue,
5
5
  fetchLinearIssue,
6
6
  updateLinearIssueState
7
- } from "./chunk-RNBIISBZ.js";
7
+ } from "./chunk-ENGCJIYQ.js";
8
8
  import {
9
9
  GitHubService
10
- } from "./chunk-PVW6JE7E.js";
10
+ } from "./chunk-Y5HSSIK2.js";
11
11
  import {
12
12
  promptConfirmation
13
13
  } from "./chunk-7JDMYTFZ.js";
@@ -221,4 +221,4 @@ var IssueTrackerFactory = class {
221
221
  export {
222
222
  IssueTrackerFactory
223
223
  };
224
- //# sourceMappingURL=chunk-SC6X5EBG.js.map
224
+ //# sourceMappingURL=chunk-3P6J4IZZ.js.map
@@ -1,7 +1,7 @@
1
1
  #!/usr/bin/env node
2
2
  import {
3
3
  PRManager
4
- } from "./chunk-I23OQB4Y.js";
4
+ } from "./chunk-I3HMNWQQ.js";
5
5
  import {
6
6
  calculatePortForBranch,
7
7
  calculatePortFromIdentifier
@@ -40,7 +40,7 @@ import {
40
40
  } from "./chunk-KBEIQP4G.js";
41
41
  import {
42
42
  GitHubService
43
- } from "./chunk-PVW6JE7E.js";
43
+ } from "./chunk-Y5HSSIK2.js";
44
44
  import {
45
45
  calculateForegroundColor,
46
46
  generateColorFromBranchName,
@@ -244,7 +244,7 @@ var LoomManager = class {
244
244
  * NEW: Checks for existing worktrees and reuses them if found
245
245
  */
246
246
  async createIloom(input) {
247
- var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n;
247
+ var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n, _o;
248
248
  getLogger().info("Fetching issue data...");
249
249
  const issueData = await this.fetchIssueData(input);
250
250
  if (input.type === "issue" || input.type === "pr" || input.type === "branch") {
@@ -375,16 +375,30 @@ var LoomManager = class {
375
375
  getLogger().success(`Found existing PR: ${existingPR.url}`);
376
376
  } else {
377
377
  const prTitle = (issueData == null ? void 0 : issueData.title) ?? `Work on ${branchName}`;
378
- const prBody = input.type === "issue" ? `PR for issue #${input.identifier}
378
+ let prBody;
379
+ if (input.type === "issue") {
380
+ const issueBody = (issueData == null ? void 0 : issueData.body) ? `
379
381
 
380
- This PR was created automatically by iloom.` : `Branch: ${branchName}
382
+ ## ${issueData.title}
381
383
 
382
- This PR was created automatically by iloom.`;
384
+ ${issueData.body}` : "";
385
+ prBody = `Fixes ${prManager.issuePrefix}${input.identifier}${issueBody}
386
+
387
+ ---
388
+ *This PR was created automatically by iloom.*`;
389
+ } else {
390
+ prBody = `Branch: ${branchName}
391
+
392
+ ---
393
+ *This PR was created automatically by iloom.*`;
394
+ }
395
+ const draftBaseBranch = ((_e = input.parentLoom) == null ? void 0 : _e.branchName) ?? settingsData.mainBranch ?? "main";
383
396
  getLogger().info("Creating draft PR...");
384
397
  const prResult = await prManager.createDraftPR(
385
398
  branchName,
386
399
  prTitle,
387
400
  prBody,
401
+ draftBaseBranch,
388
402
  worktreePath
389
403
  );
390
404
  draftPrNumber = prResult.number;
@@ -418,13 +432,13 @@ This PR was created automatically by iloom.`;
418
432
  );
419
433
  }
420
434
  }
421
- const enableClaude = ((_e = input.options) == null ? void 0 : _e.enableClaude) !== false;
422
- const enableCode = ((_f = input.options) == null ? void 0 : _f.enableCode) !== false;
423
- const enableDevServer = ((_g = input.options) == null ? void 0 : _g.enableDevServer) !== false;
424
- const enableTerminal = ((_h = input.options) == null ? void 0 : _h.enableTerminal) ?? false;
425
- const oneShot = ((_i = input.options) == null ? void 0 : _i.oneShot) ?? "default";
426
- const setArguments = (_j = input.options) == null ? void 0 : _j.setArguments;
427
- const executablePath = (_k = input.options) == null ? void 0 : _k.executablePath;
435
+ const enableClaude = ((_f = input.options) == null ? void 0 : _f.enableClaude) !== false;
436
+ const enableCode = ((_g = input.options) == null ? void 0 : _g.enableCode) !== false;
437
+ const enableDevServer = ((_h = input.options) == null ? void 0 : _h.enableDevServer) !== false;
438
+ const enableTerminal = ((_i = input.options) == null ? void 0 : _i.enableTerminal) ?? false;
439
+ const oneShot = ((_j = input.options) == null ? void 0 : _j.oneShot) ?? "default";
440
+ const setArguments = (_k = input.options) == null ? void 0 : _k.setArguments;
441
+ const executablePath = (_l = input.options) == null ? void 0 : _l.executablePath;
428
442
  if (enableClaude || enableCode || enableDevServer || enableTerminal) {
429
443
  const { LoomLauncher } = await import("./LoomLauncher-3I47SUPV.js");
430
444
  const { ClaudeContextManager } = await import("./ClaudeContextManager-X2Y72GRL.js");
@@ -446,7 +460,7 @@ This PR was created automatically by iloom.`;
446
460
  ...setArguments && { setArguments },
447
461
  ...executablePath && { executablePath },
448
462
  sourceEnvOnStart: settingsData.sourceEnvOnStart ?? false,
449
- colorTerminal: ((_l = input.options) == null ? void 0 : _l.colorTerminal) ?? ((_m = settingsData.colors) == null ? void 0 : _m.terminal) ?? true,
463
+ colorTerminal: ((_m = input.options) == null ? void 0 : _m.colorTerminal) ?? ((_n = settingsData.colors) == null ? void 0 : _n.terminal) ?? true,
450
464
  colorHex: colorData.hex
451
465
  });
452
466
  }
@@ -489,7 +503,7 @@ This PR was created automatically by iloom.`;
489
503
  prUrls,
490
504
  capabilities,
491
505
  ...draftPrNumber && { draftPrNumber },
492
- ...((_n = input.options) == null ? void 0 : _n.oneShot) && { oneShot: input.options.oneShot },
506
+ ...((_o = input.options) == null ? void 0 : _o.oneShot) && { oneShot: input.options.oneShot },
493
507
  ...input.parentLoom && { parentLoom: input.parentLoom }
494
508
  };
495
509
  await this.metadataManager.writeMetadata(worktreePath, metadataInput);
@@ -1950,6 +1964,7 @@ var ResourceCleanup = class {
1950
1964
  rollbackRequired: false
1951
1965
  };
1952
1966
  }
1967
+ let safetyCheckPassed = false;
1953
1968
  if (!options.force) {
1954
1969
  const shouldCheckMergeSafety = options.checkMergeSafety ?? options.deleteBranch === true;
1955
1970
  const shouldCheckRemoteBranch = options.checkRemoteBranch ?? false;
@@ -1960,6 +1975,7 @@ var ResourceCleanup = class {
1960
1975
 
1961
1976
  ${blockerMessage}`);
1962
1977
  }
1978
+ safetyCheckPassed = true;
1963
1979
  if (safety.warnings.length > 0) {
1964
1980
  safety.warnings.forEach((warning) => {
1965
1981
  getLogger().warn(warning);
@@ -2073,7 +2089,8 @@ ${blockerMessage}`);
2073
2089
  } else {
2074
2090
  try {
2075
2091
  const branchOptions = {
2076
- dryRun: false
2092
+ dryRun: false,
2093
+ safetyVerified: safetyCheckPassed
2077
2094
  };
2078
2095
  if (mergeTargetBranch !== null) {
2079
2096
  branchOptions.mergeTargetBranch = mergeTargetBranch;
@@ -2316,9 +2333,9 @@ ${blockerMessage}`);
2316
2333
  getLogger().info(`[DRY RUN] Would delete branch: ${branchName}`);
2317
2334
  return true;
2318
2335
  }
2336
+ let deleteCwd = workingDir;
2319
2337
  try {
2320
2338
  let deleteFlag = "-d";
2321
- let deleteCwd = workingDir;
2322
2339
  if (options.force) {
2323
2340
  deleteFlag = "-D";
2324
2341
  } else if (options.mergeTargetBranch) {
@@ -2373,6 +2390,12 @@ ${blockerMessage}`);
2373
2390
  throw error;
2374
2391
  }
2375
2392
  if (errorMessage.includes("not fully merged")) {
2393
+ if (options.safetyVerified) {
2394
+ getLogger().info(`Branch '${branchName}' not merged into HEAD but safety verified - using force delete`);
2395
+ await executeGitCommand(["branch", "-D", branchName], { cwd: deleteCwd });
2396
+ getLogger().info(`Branch deleted: ${branchName}`);
2397
+ return true;
2398
+ }
2376
2399
  throw new Error(
2377
2400
  `Cannot delete unmerged branch '${branchName}'. Use --force to delete anyway.`
2378
2401
  );
@@ -2582,4 +2605,4 @@ export {
2582
2605
  DatabaseManager,
2583
2606
  ResourceCleanup
2584
2607
  };
2585
- //# sourceMappingURL=chunk-6Y3FTRJL.js.map
2608
+ //# sourceMappingURL=chunk-4ZIHFUPN.js.map