episoda 0.2.34 → 0.2.36

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/index.js CHANGED
@@ -390,6 +390,9 @@ var require_git_executor = __commonJS({
390
390
  return await this.executeWorktreeList(cwd, options);
391
391
  case "worktree_prune":
392
392
  return await this.executeWorktreePrune(cwd, options);
393
+ // EP1002: Worktree setup command for unified orchestration
394
+ case "worktree_setup":
395
+ return await this.executeWorktreeSetup(command, cwd, options);
393
396
  case "clone_bare":
394
397
  return await this.executeCloneBare(command, options);
395
398
  case "project_info":
@@ -1703,6 +1706,10 @@ var require_git_executor = __commonJS({
1703
1706
  args.push(command.path);
1704
1707
  const result = await this.runGitCommand(args, cwd, options);
1705
1708
  if (result.success) {
1709
+ try {
1710
+ await fs15.rm(command.path, { recursive: true, force: true });
1711
+ } catch {
1712
+ }
1706
1713
  return {
1707
1714
  success: true,
1708
1715
  output: `Removed worktree at ${command.path}`,
@@ -1816,6 +1823,18 @@ var require_git_executor = __commonJS({
1816
1823
  };
1817
1824
  }
1818
1825
  }
1826
+ /**
1827
+ * EP1002: Worktree setup command stub
1828
+ * The actual implementation is in the daemon which intercepts this command.
1829
+ * This stub exists for type checking and as a fallback.
1830
+ */
1831
+ async executeWorktreeSetup(command, cwd, options) {
1832
+ return {
1833
+ success: false,
1834
+ error: "NOT_IMPLEMENTED",
1835
+ output: "worktree_setup must be handled by the daemon, not GitExecutor"
1836
+ };
1837
+ }
1819
1838
  /**
1820
1839
  * EP944: Clone a repository as a bare repository
1821
1840
  * Used for worktree-based development setup
@@ -2586,6 +2605,9 @@ var require_errors = __commonJS({
2586
2605
  "WORKTREE_NOT_FOUND": "Worktree not found at this path",
2587
2606
  "WORKTREE_LOCKED": "Worktree is locked",
2588
2607
  "BRANCH_IN_USE": "Branch is already checked out in another worktree",
2608
+ // EP1002: Worktree setup error messages
2609
+ "NOT_IMPLEMENTED": "Command not implemented in this context",
2610
+ "SETUP_FAILED": "Worktree setup failed",
2589
2611
  "UNKNOWN_ERROR": "Unknown error occurred"
2590
2612
  };
2591
2613
  let message = messages[code] || `Error: ${code}`;