@sideboard-ai/core 0.1.84 → 0.1.85

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 (35) hide show
  1. package/dist/{agents-OPTHS4IX.js → agents-FD77JUOP.js} +10 -10
  2. package/dist/{agents-JFXM66QA.js → agents-YAYNNJWC.js} +6 -6
  3. package/dist/{chunk-ODZ2ZOA4.js → chunk-2N5DVTGH.js} +2 -2
  4. package/dist/{chunk-BBQ6HXKS.js → chunk-3CCRD6WS.js} +19 -9
  5. package/dist/{chunk-AE5VBOFE.js → chunk-3KETJKYA.js} +9 -2
  6. package/dist/{chunk-WJ5TINR6.js → chunk-6GKDYUTJ.js} +2 -2
  7. package/dist/{chunk-VROPG6QF.js → chunk-6K5VAPVR.js} +3 -3
  8. package/dist/{chunk-CKBIQ54F.js → chunk-6WQAYBVE.js} +88 -20
  9. package/dist/{chunk-BTL7EMGT.js → chunk-HHTHF5BQ.js} +4 -4
  10. package/dist/{chunk-UN3LVQB2.js → chunk-JFQ2M6NQ.js} +2 -2
  11. package/dist/{chunk-OIEFHOP7.js → chunk-JTHWVYSD.js} +2 -2
  12. package/dist/{chunk-XW47PL6A.js → chunk-KRAUS3RF.js} +86 -16
  13. package/dist/{chunk-D4DPQ552.js → chunk-LGXBYZZA.js} +9 -2
  14. package/dist/{chunk-JPHG2KCC.js → chunk-SH75CXJR.js} +1 -1
  15. package/dist/{chunk-R753UFSX.js → chunk-WGI6KXKJ.js} +14 -4
  16. package/dist/{chunk-NW7MEJHO.js → chunk-XVFV56JG.js} +1 -1
  17. package/dist/{connected-teams-ZRS53OAT.js → connected-teams-BNBM7OIC.js} +2 -2
  18. package/dist/{connected-teams-35EIRJCP.js → connected-teams-LSQ5TAZP.js} +2 -2
  19. package/dist/{coordinator-prompt-RCTIIZ6C.js → coordinator-prompt-VN7FF76K.js} +3 -3
  20. package/dist/{coordinator-prompt-DOIOSLUN.js → coordinator-prompt-YYQSPLIP.js} +3 -3
  21. package/dist/{global-workspace-73OAKD3C.js → global-workspace-BRIDCBMY.js} +4 -4
  22. package/dist/{global-workspace-33BIG7KK.js → global-workspace-U3XVTQLL.js} +4 -4
  23. package/dist/index.cjs +181 -82
  24. package/dist/index.d.cts +32 -6
  25. package/dist/index.d.ts +32 -6
  26. package/dist/index.js +36 -22
  27. package/dist/mcp/run-stdio.cjs +361 -270
  28. package/dist/mcp/run-stdio.js +34 -27
  29. package/dist/{run-V2WZUMJA.js → run-CFKZPY7F.js} +1 -1
  30. package/dist/{run-A4RHY7HH.js → run-XKTAJRWF.js} +1 -1
  31. package/dist/{workspaces-WDLY34MX.js → workspaces-AIZDG6PS.js} +5 -5
  32. package/dist/{workspaces-SRITISKA.js → workspaces-IWQIWAMQ.js} +5 -5
  33. package/dist/{worktree-TUAO74SI.js → worktree-6ZALJUWG.js} +2 -2
  34. package/dist/{worktree-SGZVAWOQ.js → worktree-7Y22WHR7.js} +2 -2
  35. package/package.json +1 -1
@@ -17,14 +17,14 @@ import {
17
17
  resolveQuotaFallbackAgent,
18
18
  sideboardMcpProfile,
19
19
  summarizeTurnStderr
20
- } from "../chunk-BBQ6HXKS.js";
21
- import "../chunk-VROPG6QF.js";
20
+ } from "../chunk-3CCRD6WS.js";
21
+ import "../chunk-6K5VAPVR.js";
22
22
  import {
23
23
  addWorkspace,
24
24
  ensureWorkspace,
25
25
  removeWorkspace,
26
26
  syncWorkspacesFromThreads
27
- } from "../chunk-UN3LVQB2.js";
27
+ } from "../chunk-JFQ2M6NQ.js";
28
28
  import {
29
29
  extractPresentedPlan,
30
30
  readPlanFile,
@@ -42,14 +42,14 @@ import {
42
42
  isGlobalThread,
43
43
  isOrchestratorThread,
44
44
  orchestratorSessionPoisonedByBuiltins
45
- } from "../chunk-WJ5TINR6.js";
45
+ } from "../chunk-6GKDYUTJ.js";
46
46
  import {
47
47
  SLACK_REPLY_FORMATTING,
48
48
  coordinatorSystemPrompt,
49
49
  coordinatorTurnReminder,
50
50
  enrichWorkspacesWithGithub,
51
51
  ensureGlobalCoordinatorCwd
52
- } from "../chunk-NW7MEJHO.js";
52
+ } from "../chunk-XVFV56JG.js";
53
53
  import {
54
54
  addPrStackLayer,
55
55
  allocateTeamName,
@@ -80,6 +80,7 @@ import {
80
80
  originGhRepoEnv,
81
81
  pushBranch,
82
82
  removeWorktree,
83
+ resolveAgentGitAuthEnv,
83
84
  resolveDefaultBranch,
84
85
  resolveDiffBaseRef,
85
86
  resolveGithubRepoSlug,
@@ -88,7 +89,7 @@ import {
88
89
  takenSlugsFromThread,
89
90
  threadDisplayLabel,
90
91
  worktreeNameFromPath
91
- } from "../chunk-CKBIQ54F.js";
92
+ } from "../chunk-6WQAYBVE.js";
92
93
  import {
93
94
  ATTACHMENTS_DIR,
94
95
  LEGACY_ATTACHMENTS_DIR,
@@ -106,13 +107,6 @@ import {
106
107
  withThreadLock,
107
108
  writeThread
108
109
  } from "../chunk-7FD7COKE.js";
109
- import {
110
- enrichPathWithNpmGlobalBin,
111
- ensureAgentPath,
112
- gh,
113
- git,
114
- run
115
- } from "../chunk-AE5VBOFE.js";
116
110
  import {
117
111
  childEnvWithAppSettings,
118
112
  disconnectLinearConnection,
@@ -144,6 +138,13 @@ import {
144
138
  workspaceSettingsSourceLabel,
145
139
  worktreesRoot
146
140
  } from "../chunk-7MV3RXSC.js";
141
+ import {
142
+ enrichPathWithNpmGlobalBin,
143
+ ensureAgentPath,
144
+ gh,
145
+ git,
146
+ run
147
+ } from "../chunk-3KETJKYA.js";
147
148
 
148
149
  // src/mcp/server.ts
149
150
  import { McpServer } from "@modelcontextprotocol/sdk/server/mcp.js";
@@ -893,9 +894,9 @@ async function spawnAgentTurn(thread, input, onEvent) {
893
894
  `Cannot spawn ${thread.agent}: thread ${thread.id} has no worktreePath`
894
895
  );
895
896
  }
896
- const { isGlobalThread: isGlobalThread2 } = await import("../global-workspace-33BIG7KK.js");
897
+ const { isGlobalThread: isGlobalThread2 } = await import("../global-workspace-U3XVTQLL.js");
897
898
  if (isGlobalThread2(thread)) {
898
- const { ensureGlobalCoordinatorCwd: ensureGlobalCoordinatorCwd2 } = await import("../coordinator-prompt-DOIOSLUN.js");
899
+ const { ensureGlobalCoordinatorCwd: ensureGlobalCoordinatorCwd2 } = await import("../coordinator-prompt-YYQSPLIP.js");
899
900
  ensureGlobalCoordinatorCwd2(
900
901
  isOrchestratorThread(thread) ? { orchestratorThreadId: thread.id } : void 0
901
902
  );
@@ -911,14 +912,16 @@ async function spawnAgentTurn(thread, input, onEvent) {
911
912
  );
912
913
  }
913
914
  const env = childEnvWithAppSettings(cmd.env);
914
- if (!isOrchestratorThread(thread)) {
915
- try {
915
+ try {
916
+ if (isOrchestratorThread(thread)) {
917
+ Object.assign(env, await resolveAgentGitAuthEnv(env));
918
+ } else {
916
919
  const originEnv = await originGhRepoEnv(thread.worktreePath, { env });
917
920
  Object.assign(env, originEnv);
918
- } catch (err) {
919
- const detail = err instanceof Error ? err.message : String(err);
920
- console.warn(`[sideboard] originGhRepoEnv failed (${thread.worktreePath}): ${detail}`);
921
921
  }
922
+ } catch (err) {
923
+ const detail = err instanceof Error ? err.message : String(err);
924
+ console.warn(`[sideboard] git auth env failed (${thread.worktreePath}): ${detail}`);
922
925
  }
923
926
  const child = execa(cmd.file, cmd.args, {
924
927
  cwd: cmd.cwd,
@@ -1300,6 +1303,10 @@ async function spawnWorkspaceScript(command, opts) {
1300
1303
  },
1301
1304
  loginEnv
1302
1305
  );
1306
+ try {
1307
+ Object.assign(env, await resolveAgentGitAuthEnv(env, { cwd: opts.worktreePath }));
1308
+ } catch {
1309
+ }
1303
1310
  const shell = process.platform === "darwin" ? "zsh" : "bash";
1304
1311
  const child = execa2(shell, ["-lc", command], {
1305
1312
  cwd: opts.worktreePath,
@@ -1818,7 +1825,7 @@ async function createThread(input, _onSetupLine) {
1818
1825
  return readThread(thread.id) ?? thread;
1819
1826
  }
1820
1827
  async function listLinearIssues(agent, repoPath) {
1821
- const { getAdapter: getAdapter2 } = await import("../agents-OPTHS4IX.js");
1828
+ const { getAdapter: getAdapter2 } = await import("../agents-FD77JUOP.js");
1822
1829
  await requireAgent(agent, { requireLinear: true });
1823
1830
  const adapter = getAdapter2(agent);
1824
1831
  if (!adapter.listLinearIssues) {
@@ -2671,7 +2678,7 @@ async function adoptThread(input) {
2671
2678
  throw new Error(`Worktree not found: ${input.worktreePath}`);
2672
2679
  }
2673
2680
  const repoPath = await resolveRepoRoot(input.worktreePath);
2674
- const { stdout: branch } = await import("../run-A4RHY7HH.js").then(
2681
+ const { stdout: branch } = await import("../run-XKTAJRWF.js").then(
2675
2682
  ({ git: git2 }) => git2(["rev-parse", "--abbrev-ref", "HEAD"], input.worktreePath)
2676
2683
  );
2677
2684
  const thread = createEmptyThread({
@@ -2686,7 +2693,7 @@ async function adoptThread(input) {
2686
2693
  messages: input.messages ?? []
2687
2694
  });
2688
2695
  writeThread(thread);
2689
- const { ensureWorkspace: ensureWorkspace2 } = await import("../workspaces-WDLY34MX.js");
2696
+ const { ensureWorkspace: ensureWorkspace2 } = await import("../workspaces-AIZDG6PS.js");
2690
2697
  await ensureWorkspace2(repoPath);
2691
2698
  return thread;
2692
2699
  }
@@ -3921,7 +3928,7 @@ async function previewLand(thread) {
3921
3928
  const target = await resolveDefaultBranch(thread.repoPath);
3922
3929
  if (thread.branchName === target || thread.branchName === "main" || thread.branchName === "master") {
3923
3930
  }
3924
- const { stdout: head } = await import("../run-A4RHY7HH.js").then(
3931
+ const { stdout: head } = await import("../run-XKTAJRWF.js").then(
3925
3932
  ({ git: git2 }) => git2(["rev-parse", "--abbrev-ref", "HEAD"], thread.worktreePath)
3926
3933
  );
3927
3934
  const current = head.trim();
@@ -3960,7 +3967,7 @@ async function confirmLand(thread, opts) {
3960
3967
  if (preview.dirty) {
3961
3968
  committed = await commitAll(thread.worktreePath, meta.commitMessage);
3962
3969
  }
3963
- const { git: git2 } = await import("../run-A4RHY7HH.js");
3970
+ const { git: git2 } = await import("../run-XKTAJRWF.js");
3964
3971
  const { stdout: headOut } = await git2(
3965
3972
  ["rev-parse", "--abbrev-ref", "HEAD"],
3966
3973
  thread.worktreePath,
@@ -6111,7 +6118,7 @@ var Orchestrator = class {
6111
6118
  this.emit({ type: "status_changed", threadId: archived.id, status: "archived" });
6112
6119
  if (thread.repoPath && !isGlobalRepoPath(thread.repoPath)) {
6113
6120
  try {
6114
- const { ensureWorkspace: ensureWorkspace2 } = await import("../workspaces-WDLY34MX.js");
6121
+ const { ensureWorkspace: ensureWorkspace2 } = await import("../workspaces-AIZDG6PS.js");
6115
6122
  await ensureWorkspace2(thread.repoPath);
6116
6123
  } catch {
6117
6124
  }
@@ -6154,7 +6161,7 @@ var Orchestrator = class {
6154
6161
  return restored2;
6155
6162
  }
6156
6163
  if (!existsSync15(thread.worktreePath)) {
6157
- const { createThreadWorktree: createThreadWorktree2 } = await import("../worktree-TUAO74SI.js");
6164
+ const { createThreadWorktree: createThreadWorktree2 } = await import("../worktree-6ZALJUWG.js");
6158
6165
  const { execa: execa6 } = await import("execa");
6159
6166
  const slug = thread.worktreePath.split("/").pop();
6160
6167
  const dest = thread.worktreePath;
@@ -3,7 +3,7 @@ import {
3
3
  git,
4
4
  resolveGhAuthToken,
5
5
  run
6
- } from "./chunk-D4DPQ552.js";
6
+ } from "./chunk-LGXBYZZA.js";
7
7
  export {
8
8
  gh,
9
9
  git,
@@ -5,7 +5,7 @@ import {
5
5
  git,
6
6
  resolveGhAuthToken,
7
7
  run
8
- } from "./chunk-AE5VBOFE.js";
8
+ } from "./chunk-3KETJKYA.js";
9
9
  export {
10
10
  gh,
11
11
  git,
@@ -6,17 +6,17 @@ import {
6
6
  listWorkspaces,
7
7
  removeWorkspace,
8
8
  syncWorkspacesFromThreads
9
- } from "./chunk-UN3LVQB2.js";
10
- import "./chunk-WJ5TINR6.js";
11
- import "./chunk-NW7MEJHO.js";
12
- import "./chunk-CKBIQ54F.js";
9
+ } from "./chunk-JFQ2M6NQ.js";
10
+ import "./chunk-6GKDYUTJ.js";
11
+ import "./chunk-XVFV56JG.js";
12
+ import "./chunk-6WQAYBVE.js";
13
13
  import "./chunk-B3SJXYIJ.js";
14
14
  import "./chunk-7FD7COKE.js";
15
- import "./chunk-AE5VBOFE.js";
16
15
  import "./chunk-AY53MPDE.js";
17
16
  import "./chunk-NSTQ6QKD.js";
18
17
  import "./chunk-KGZBYWZ3.js";
19
18
  import "./chunk-7MV3RXSC.js";
19
+ import "./chunk-3KETJKYA.js";
20
20
  export {
21
21
  addWorkspace,
22
22
  ensureWorkspace,
@@ -4,10 +4,10 @@ import {
4
4
  listWorkspaces,
5
5
  removeWorkspace,
6
6
  syncWorkspacesFromThreads
7
- } from "./chunk-ODZ2ZOA4.js";
8
- import "./chunk-OIEFHOP7.js";
9
- import "./chunk-JPHG2KCC.js";
10
- import "./chunk-XW47PL6A.js";
7
+ } from "./chunk-2N5DVTGH.js";
8
+ import "./chunk-JTHWVYSD.js";
9
+ import "./chunk-SH75CXJR.js";
10
+ import "./chunk-KRAUS3RF.js";
11
11
  import "./chunk-FKOIHGKV.js";
12
12
  import "./chunk-I3FRXL7J.js";
13
13
  import "./chunk-5KLC2MWZ.js";
@@ -15,7 +15,7 @@ import "./chunk-JT7R45JB.js";
15
15
  import "./chunk-FWJYLBO6.js";
16
16
  import "./chunk-77WWLBCI.js";
17
17
  import "./chunk-M37RITA6.js";
18
- import "./chunk-D4DPQ552.js";
18
+ import "./chunk-LGXBYZZA.js";
19
19
  export {
20
20
  addWorkspace,
21
21
  ensureWorkspace,
@@ -46,14 +46,14 @@ import {
46
46
  worktreeDisplayLabel,
47
47
  worktreeDisplayLabelForGroup,
48
48
  worktreeNameFromPath
49
- } from "./chunk-CKBIQ54F.js";
49
+ } from "./chunk-6WQAYBVE.js";
50
50
  import "./chunk-B3SJXYIJ.js";
51
51
  import "./chunk-7FD7COKE.js";
52
- import "./chunk-AE5VBOFE.js";
53
52
  import "./chunk-AY53MPDE.js";
54
53
  import "./chunk-NSTQ6QKD.js";
55
54
  import "./chunk-KGZBYWZ3.js";
56
55
  import "./chunk-7MV3RXSC.js";
56
+ import "./chunk-3KETJKYA.js";
57
57
  export {
58
58
  FAMOUS_SOCCER_TEAMS,
59
59
  allocateTeamName,
@@ -44,7 +44,7 @@ import {
44
44
  worktreeDisplayLabel,
45
45
  worktreeDisplayLabelForGroup,
46
46
  worktreeNameFromPath
47
- } from "./chunk-XW47PL6A.js";
47
+ } from "./chunk-KRAUS3RF.js";
48
48
  import "./chunk-FKOIHGKV.js";
49
49
  import "./chunk-I3FRXL7J.js";
50
50
  import "./chunk-5KLC2MWZ.js";
@@ -52,7 +52,7 @@ import "./chunk-JT7R45JB.js";
52
52
  import "./chunk-FWJYLBO6.js";
53
53
  import "./chunk-77WWLBCI.js";
54
54
  import "./chunk-M37RITA6.js";
55
- import "./chunk-D4DPQ552.js";
55
+ import "./chunk-LGXBYZZA.js";
56
56
  export {
57
57
  FAMOUS_SOCCER_TEAMS,
58
58
  allocateTeamName,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sideboard-ai/core",
3
- "version": "0.1.84",
3
+ "version": "0.1.85",
4
4
  "description": "Sideboard core — orchestration, agents, git worktrees, MCP server",
5
5
  "license": "Apache-2.0",
6
6
  "type": "module",