@overdeck/desktop 0.47.0 → 0.48.0

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 (444) hide show
  1. package/drizzle/overdeck/0000_overdeck_init.sql +59 -0
  2. package/package.json +1 -1
  3. package/server/{acceptance-criteria-10Ur5Dne.js → acceptance-criteria-DmtLDbtt.js} +2 -2
  4. package/server/{activity-logger-CyteR4JO.js → activity-logger-Co5qljIj.js} +55 -4
  5. package/server/activity-logger-K7FYGF_z.js +3 -0
  6. package/server/{advancing-selfheal-BNwqxseD.js → advancing-selfheal-8AR68Asf.js} +6 -6
  7. package/server/{agent-gc-C3h9Or3a.js → agent-gc-BmYeT6eH.js} +5 -5
  8. package/server/agent-state-Dq3s84-P.js +3 -0
  9. package/server/{agent-state-service-C63p_ftq.js → agent-state-service-DK1Vay1E.js} +1 -1
  10. package/server/{agent-state-service-Ds6OeFvo.js → agent-state-service-rjnzpHDx.js} +6 -6
  11. package/server/agent-state-source-Ds968-j6.js +21 -0
  12. package/server/{agents-J5mEnekq.js → agents-Dls7tfJH.js} +5 -5
  13. package/server/agents-IPSa5kzn.js +3 -0
  14. package/server/{archive-planning-BwhxeP7C.js → archive-planning-Cq7cyinS.js} +51 -24
  15. package/server/archive-planning-MbkGCBIY.js +2 -0
  16. package/server/{artifact-index-jobs-D1q_vR3V.js → artifact-index-jobs-Dj_8kpTd.js} +3 -3
  17. package/server/{assemble-Bgwqv-Ro.js → assemble-BTCmbcfH.js} +20 -13
  18. package/server/{auto-spawn-consent-CQ9Bi9q6.js → auto-spawn-consent-lXqRJ1Dr.js} +304 -121
  19. package/server/{backlog-auto-trigger-n1lzPgN4.js → backlog-auto-trigger-Dn-amzt6.js} +3 -3
  20. package/server/{behavior-td6-xhQk.js → behavior-DIMQMRzs.js} +2 -2
  21. package/server/{boot-reconciled-stop-events-C7gGe3oB.js → boot-reconciled-stop-events-D6SeUTIr.js} +1 -1
  22. package/server/{bridge-pool-patrol-CYH2OLb5.js → bridge-pool-patrol-BEjt-xF3.js} +2 -2
  23. package/server/{briefing-freshness-DRqZ8lAz.js → briefing-freshness-3PNmL_p3.js} +2 -2
  24. package/server/{build-info-7yiEpl6u.js → build-info-CJg813Hm.js} +3 -3
  25. package/server/{build-info-CpG__c63.js → build-info-CXyeFsXu.js} +1 -1
  26. package/server/{checkpoint-manager-CkKmB0wZ.js → checkpoint-manager-9t7G5c1V.js} +1 -1
  27. package/server/{checkpoint-manager-DBcyNR8w.js → checkpoint-manager-B2G38R3p.js} +3 -3
  28. package/server/checkpoint-worker.js +1 -1
  29. package/server/{checkpoints-Wm963lm8.js → checkpoints-CuBgiXO-.js} +1 -1
  30. package/server/{checkpoints-D95apurL.js → checkpoints-VTZMd4Qm.js} +2 -2
  31. package/server/{claude-hooks-provision-Bjitl9aI.js → claude-hooks-provision-55SyQaPz.js} +2 -2
  32. package/server/{claude-hooks-provision-4RPxNkE8.js → claude-hooks-provision-CEUT-CZd.js} +1 -1
  33. package/server/{claude-permissions-CpbpvUQ2.js → claude-permissions-Cn0dIu2i.js} +2 -2
  34. package/server/{claude-settings-overlay-BzkHYDwR.js → claude-settings-overlay-B19hdzSA.js} +1 -1
  35. package/server/{claude-settings-overlay-_H9Yrzab.js → claude-settings-overlay-Yg_ANh81.js} +2 -2
  36. package/server/{cli-Cte9ZFGn.js → cli-C9S84iTy.js} +79 -22
  37. package/server/cli-M1cwZ__d.js +3 -0
  38. package/server/{cliproxy-C5fMJ7rY.js → cliproxy-CJq3KXU6.js} +2 -2
  39. package/server/{cliproxy-DaAbWMjC.js → cliproxy-DgEZlr7Y.js} +1 -1
  40. package/server/{close-issue-BPh1ARCF.js → close-issue-DPxRddGR.js} +5 -5
  41. package/server/{closed-issue-reaper-DoOZqGFK.js → closed-issue-reaper-C5Zn4GRS.js} +13 -13
  42. package/server/{closed-issue-reaper-DHRfRMrp.js → closed-issue-reaper-D-2B48Ri.js} +1 -1
  43. package/server/{codex-o8FJwzmy.js → codex-B3n_rkwn.js} +1 -1
  44. package/server/{codex-BzGDW_d3.js → codex-CjkD1PJu.js} +6 -6
  45. package/server/{codex-parser-Dt-ycU8L.js → codex-parser-DpB1Il-P.js} +2 -2
  46. package/server/{compaction-continuation-CvXpbZ4w.js → compaction-continuation-DZD9ukSE.js} +3 -3
  47. package/server/{config-CL3Gyvja.js → config-C5saf4Ja.js} +1 -1
  48. package/server/{config-BvLe652W.js → config-DnLJATZk.js} +2 -2
  49. package/server/{config-Bi3u1VK7.js → config-DvM8jtQK.js} +2 -2
  50. package/server/{config-yaml-CxdwhAIA.js → config-yaml-BSCqwmX0.js} +11299 -10972
  51. package/server/{conflict-gate-CX80JYYS.js → conflict-gate-DXa_L28t.js} +1 -1
  52. package/server/{conflict-gate-E4nt7ZeS.js → conflict-gate-WfVqgalf.js} +4 -4
  53. package/server/{context-layers-DAG83UZt.js → context-layers-D7UqH9Ab.js} +2 -2
  54. package/server/{context-layers-C_IIysnm.js → context-layers-Dpz3Vd6d.js} +3 -3
  55. package/server/{control-settings-CiqGxXnc.js → control-settings-DVf6pKyv.js} +4 -4
  56. package/server/{conversation-compaction-BE3CNtHF.js → conversation-compaction-5XuH6OBn.js} +1 -1
  57. package/server/{conversation-compaction-D6-yLtqt.js → conversation-compaction-COrbnX1J.js} +8 -8
  58. package/server/{conversation-service-DBxoYMDl.js → conversation-service-BufdtnZF.js} +169 -10
  59. package/server/{conversation-service-D_TS2b1r.js → conversation-service-DnUyIiLb.js} +1 -1
  60. package/server/{conversations-D0UEdLtk.js → conversations-B4rxz-Wl.js} +17 -10
  61. package/server/{conversations-BKDVpB-3.js → conversations-D1bwxQMy.js} +1 -1
  62. package/server/{cost-DpgYmYqR.js → cost-CpFDrJUS.js} +46 -2
  63. package/server/{cost-DS1s0DbG.js → cost-KLuwKCW9.js} +3 -3
  64. package/server/{cost-sync-tOCCGnEt.js → cost-sync-cesi9dp8.js} +3 -3
  65. package/server/{dag-BtkgLeqY.js → dag-BYiFMqpU.js} +2 -2
  66. package/server/{dangerous-git-ops-CFLykHWt.js → dangerous-git-ops-BKvd3-Hk.js} +1 -1
  67. package/server/dashboard-db-worker.js +7 -7
  68. package/server/{deacon-BIblC-WX.js → deacon-BbsWw8a6.js} +3 -3
  69. package/server/{deacon-pLRLbPvR.js → deacon-HdEh0Esp.js} +863 -214
  70. package/server/deacon-event-client-C93rvOT7.js +237 -0
  71. package/server/deacon-event-client-Ck5Ei7Mn.js +3 -0
  72. package/server/{deacon-nudge-log-B08gF0mh.js → deacon-nudge-log-BND_97Wo.js} +4 -3
  73. package/server/{deacon-pending-lifecycle-B-Io84AP.js → deacon-pending-lifecycle-CD3YsiQK.js} +3 -3
  74. package/server/deacon-swarm-DgWADWd_.js +2 -0
  75. package/server/{deacon-swarm-v5PMun-m.js → deacon-swarm-rqrl4TMs.js} +39 -18
  76. package/server/deacon.js +12 -210
  77. package/server/{dead-end-trip-D8A3msX9.js → dead-end-trip-DSF23CLX.js} +4 -3
  78. package/server/dead-end-trip-zKlS4v6f.js +2 -0
  79. package/server/delivery-CsbQdZkS.js +3 -0
  80. package/server/{deploy-patrol-sYgOxLeb.js → deploy-patrol-kARAkji4.js} +17 -21
  81. package/server/{deploy-queue-VfohaPN_.js → deploy-queue-Bj0HJT1i.js} +2 -2
  82. package/server/{deploy-queue-gHJBycaF.js → deploy-queue-rjTUy1RM.js} +1 -1
  83. package/server/{deploy-window-D4DQb8VP.js → deploy-window-B2IM-9G5.js} +10 -44
  84. package/server/{deploy-window-CFRZ0-kt.js → deploy-window-BNFWnA8D.js} +1 -1
  85. package/server/{dev-supervisor-DiOBDM1c.js → dev-supervisor-B1mZYXz4.js} +2 -2
  86. package/server/{devcontainer-renderer-BUOIlfgD.js → devcontainer-renderer-B-o68Z5B.js} +3 -3
  87. package/server/{dist-C3A8B8wM.js → dist-3W--cGMa.js} +1 -1
  88. package/server/dist-BR0QtwmS.js +3 -0
  89. package/server/{dist-src-C0adpegX.js → dist-src-C-Vk2jNk.js} +1 -1
  90. package/server/{docker-Y3PElJb0.js → docker-DH3jUYg1.js} +1 -1
  91. package/server/{docker-BJzlkqYB.js → docker-meuLKLzV.js} +27 -20
  92. package/server/{dod-DlNtcH6n.js → dod-D7-9dCOD.js} +1 -1
  93. package/server/{driver-CKVGi51s.js → driver-CmsY2RLl.js} +1 -1
  94. package/server/{durable-review-pipeline-DP6bIcOY.js → durable-review-pipeline-CStTgOAf.js} +1 -1
  95. package/server/{durable-review-pipeline-Cibps-Rg.js → durable-review-pipeline-Chq0lzjL.js} +1 -1
  96. package/server/{ensure-devcontainer-DMAbWqtQ.js → ensure-devcontainer-BE3llBWP.js} +1 -1
  97. package/server/{ensure-devcontainer-BAofzBPv.js → ensure-devcontainer-BXrY7C2Z.js} +4 -4
  98. package/server/{esm-shims-BeObUkaw.js → esm-shims-Bzy4ZzNU.js} +1 -1
  99. package/server/event-store-COd2tOx8.js +3 -0
  100. package/server/{event-store-CrHcVC5_.js → event-store-D_AR-Y78.js} +184 -11
  101. package/server/{events-CF8QDbuV.js → events-CCkFWa7X.js} +1 -1
  102. package/server/{events-BNrvchBg.js → events-zjDQozet.js} +3 -3
  103. package/server/{factory-Cmm9Hsho.js → factory-DhavwKVc.js} +5 -5
  104. package/server/{feature-registry-population-B6HpNWRy.js → feature-registry-population-DWGBKyWd.js} +4 -4
  105. package/server/{feature-registry-storage-DJEFx1Pf.js → feature-registry-storage-C5DkXmCM.js} +3 -3
  106. package/server/{features-D5km80UI.js → features-CC47YcCX.js} +2 -2
  107. package/server/{feedback-target-BJ5ZADsu.js → feedback-target-D9Tex35_.js} +1 -1
  108. package/server/{feedback-target-DSxEL6lP.js → feedback-target-DoRCR3L-.js} +18 -7
  109. package/server/{feedback-writer-CoB9Z6aU.js → feedback-writer-CTSuA6lw.js} +1 -1
  110. package/server/{feedback-writer-C27Hak8a.js → feedback-writer-DdsBdtNL.js} +5 -5
  111. package/server/{flywheel-DZZdtiOL.js → flywheel-DHWHzaYK.js} +1 -1
  112. package/server/{flywheel-f662Q-y2.js → flywheel-DJQa9az8.js} +14 -14
  113. package/server/{flywheel-BHx8XuMr.js → flywheel-TacAI9MA.js} +21 -17
  114. package/server/{flywheel-merge-order-Dil0LmdN.js → flywheel-merge-order-D2foPh88.js} +1 -1
  115. package/server/{flywheel-merge-order-D_xLMbJU.js → flywheel-merge-order-DRtex2Dt.js} +7 -7
  116. package/server/forge-CdlCG9aS.js +3 -0
  117. package/server/{forge-BaKGCya6.js → forge-c8LeC-tw.js} +2 -2
  118. package/server/{from-B3tZbB55.js → from-BogSwvr2.js} +1 -1
  119. package/server/{fs-lock-Bre3sGoz.js → fs-lock-D_GeJtXl.js} +3 -3
  120. package/server/{fts-operations-B9jG8wa3.js → fts-operations-DP9R-8Q3.js} +3 -3
  121. package/server/{git-utils-Xg4PFN45.js → git-utils-C31x1lpE.js} +1 -1
  122. package/server/{git-utils-CsvYfJU3.js → git-utils-xQ74FoSn.js} +5 -4
  123. package/server/{github-app-Bmg4R9mv.js → github-app-CpQSDlv8.js} +1 -1
  124. package/server/{github-app-CmNk0zLU.js → github-app-D2QuvZ3j.js} +3 -3
  125. package/server/{github-client-qazkPrg0.js → github-client-D9YvJX5D.js} +3 -3
  126. package/server/{github-client-B6KM9_wA.js → github-client-Tpi3PmKX.js} +1 -1
  127. package/server/{github-pr-lookup-DAcVeRLK.js → github-pr-lookup-DvBMv-IW.js} +2 -2
  128. package/server/{harness-binary-BSpiXaLw.js → harness-binary-BHxWf_sX.js} +7 -6
  129. package/server/{harness-resolve-BAJu5MX8.js → harness-resolve-bj9WMABA.js} +4 -4
  130. package/server/{health-events-BwX32k8d.js → health-events-bCDPn59Z.js} +2 -2
  131. package/server/{health-events-2Z6Wa9SM.js → health-events-qo7Ss34U.js} +1 -1
  132. package/server/{hooks-DbtbimEf.js → hooks-Dyxtg5fk.js} +2 -2
  133. package/server/{hooks-D1g1jKLI.js → hooks-X2XHBB2b.js} +1 -1
  134. package/server/{hume-DXNiu6nQ.js → hume-DrZEGpqc.js} +2 -2
  135. package/server/hume-YPsy4UA8.js +3 -0
  136. package/server/{idle-stack-reaper-Cy-dQzW4.js → idle-stack-reaper-CJ1ygW0p.js} +37 -7
  137. package/server/{idle-stack-reaper-CRA1e0jr.js → idle-stack-reaper-uJGOb-vu.js} +1 -1
  138. package/server/{in-flight-guard-D-sSkADM.js → in-flight-guard-CG2Eo-rr.js} +1 -1
  139. package/server/{infra-BDQDRopn.js → infra-CTrmVqc_.js} +111 -6
  140. package/server/{injection-Bl8d_jHZ.js → injection-BisQ0lpX.js} +1 -1
  141. package/server/{injection-6AGnXxlj.js → injection-C9sxqbc2.js} +73 -193
  142. package/server/{inspect-agent-nXdIptyh.js → inspect-agent-BoSO51YC.js} +12 -12
  143. package/server/inspect-agent-BykeOH4a.js +2 -0
  144. package/server/{internal-token-DzK385vD.js → internal-token-AvXePaQT.js} +2 -2
  145. package/server/{internal-token-Ias7N8Kg.js → internal-token-Djkj-yqK.js} +1 -1
  146. package/server/{io-B00PBNku.js → io-mxOWMZ7I.js} +6 -6
  147. package/server/{issue-closed-BehTG1be.js → issue-closed-Bj_bCv_0.js} +7 -7
  148. package/server/{issue-lifecycle-BqSuQvbn.js → issue-lifecycle-A5YIpDZE.js} +1 -1
  149. package/server/{issue-lifecycle-Birk-ifu.js → issue-lifecycle-BXUqaHzF.js} +32 -28
  150. package/server/{issue-service-singleton-C6ZduvuY.js → issue-service-singleton-BPNEXczv.js} +11 -11
  151. package/server/{issue-service-singleton-B2wXiIlw.js → issue-service-singleton-CcaHjKPR.js} +1 -1
  152. package/server/{issues-DQ5-LatB.js → issues-AX-YBeAQ.js} +2 -2
  153. package/server/{jsonl-parser-BDpnGFCl.js → jsonl-parser-CgYWQ20q.js} +7 -3
  154. package/server/kimi-code-BYbme0aV.js +579 -0
  155. package/server/kimi-code-D_Ppt82c.js +3 -0
  156. package/server/kimi-parser-B-JBg3Pv.js +147 -0
  157. package/server/{label-cleanup-Dwnky8FG.js → label-cleanup-sXUlgdM0.js} +3 -3
  158. package/server/{lifecycle-B4Xdb4cY.js → lifecycle-D2X3al0D.js} +2 -2
  159. package/server/{lifecycle-B3s4sM1G.js → lifecycle-DjlljAZ1.js} +6 -6
  160. package/server/{lifecycle-io-CzTHEooc.js → lifecycle-io-C5nVk55o.js} +1 -1
  161. package/server/{lifecycle-io-DCo6s6ks.js → lifecycle-io-NPm1YtIG.js} +5 -5
  162. package/server/{linear-client-CnbtHiic.js → linear-client--luYwCZg.js} +1 -1
  163. package/server/{linear-client-9uq7fhiV.js → linear-client-B8pLegW1.js} +3 -3
  164. package/server/{linear-mcp-auth-BxUOzswy.js → linear-mcp-auth-BQVWV0I3.js} +6 -6
  165. package/server/{linear-mcp-auth-D46fBCLf.js → linear-mcp-auth-Dx81Zl4G.js} +1 -1
  166. package/server/memory-fts-worker.js +1 -1
  167. package/server/{merge-DiW9RdSB.js → merge-Bx5Bh9pi.js} +3 -3
  168. package/server/{merge-sr8Nrnmi.js → merge-Dqmh_zja.js} +1 -1
  169. package/server/{merge-agent-BLUgRsz3.js → merge-agent-DP9AUY29.js} +33 -33
  170. package/server/{merge-agent-DQTXZk8z.js → merge-agent-DWd0KfiS.js} +1 -1
  171. package/server/{merge-batch-Cp_j9BGk.js → merge-batch-BdmvTEAC.js} +1 -1
  172. package/server/{merge-completeness-BLbB5-6n.js → merge-completeness-BfRwFjRx.js} +1 -1
  173. package/server/{merge-completeness-B46KqhtY.js → merge-completeness-C1FevcDT.js} +4 -4
  174. package/server/merge-ops-B98tKc1e.js +2 -0
  175. package/server/merge-rebase-BLykMwPO.js +2 -0
  176. package/server/{merge-rebase-DIkBjgwq.js → merge-rebase-BX1xKsrE.js} +2 -2
  177. package/server/{merge-set-CBgHfwM0.js → merge-set-DsLjjLEV.js} +4 -4
  178. package/server/{merge-set-DeUxFsC3.js → merge-set-H6epHOsw.js} +1 -1
  179. package/server/{merge-sync-kr4vqyjM.js → merge-sync-BEdfsQV4.js} +2 -2
  180. package/server/{merge-sync-CpGmk6Ch.js → merge-sync-BebcWWGA.js} +1 -1
  181. package/server/{merge-train-Dmrcus12.js → merge-train-D1I0lNOT.js} +4 -4
  182. package/server/{merge-train-deps-D_uGX91G.js → merge-train-deps-D_-C0Pk2.js} +4 -4
  183. package/server/{merge-verification-NvaAd8CZ.js → merge-verification-DN1Ov9bU.js} +6 -6
  184. package/server/{merged-docker-cleanup-worker-Y1R06TEl.js → merged-docker-cleanup-worker-CfXSr2pA.js} +4 -4
  185. package/server/{merged-docker-cleanup-worker-DH_hrGPI.js → merged-docker-cleanup-worker-ybsPyHjB.js} +1 -1
  186. package/server/{multipart-parser-R-oC8dQg.js → multipart-parser-CL5QG8iv.js} +2 -2
  187. package/server/{no-resume-mode-BgD0JUmM.js → no-resume-mode-DUR7Hi98.js} +1 -1
  188. package/server/node_modules/.package-lock.json +7 -7
  189. package/server/node_modules/brace-expansion/README.md +23 -1
  190. package/server/node_modules/brace-expansion/index.js +206 -85
  191. package/server/node_modules/brace-expansion/package.json +1 -1
  192. package/server/node_modules/msgpackr/dist/index-no-eval.cjs +34 -28
  193. package/server/node_modules/msgpackr/dist/index-no-eval.cjs.map +1 -1
  194. package/server/node_modules/msgpackr/dist/index-no-eval.min.js +1 -1
  195. package/server/node_modules/msgpackr/dist/index-no-eval.min.js.map +1 -1
  196. package/server/node_modules/msgpackr/dist/index.js +34 -28
  197. package/server/node_modules/msgpackr/dist/index.js.map +1 -1
  198. package/server/node_modules/msgpackr/dist/index.min.js +1 -1
  199. package/server/node_modules/msgpackr/dist/index.min.js.map +1 -1
  200. package/server/node_modules/msgpackr/dist/node.cjs +36 -29
  201. package/server/node_modules/msgpackr/dist/node.cjs.map +1 -1
  202. package/server/node_modules/msgpackr/dist/test.js +63 -32
  203. package/server/node_modules/msgpackr/dist/test.js.map +1 -1
  204. package/server/node_modules/msgpackr/dist/unpack-no-eval.cjs +34 -28
  205. package/server/node_modules/msgpackr/dist/unpack-no-eval.cjs.map +1 -1
  206. package/server/node_modules/msgpackr/package.json +1 -1
  207. package/server/node_modules/msgpackr/unpack.js +34 -28
  208. package/server/{orphan-proposed-reconciler-DcgTPPFY.js → orphan-proposed-reconciler-CEW1maPl.js} +1 -1
  209. package/server/{orphan-proposed-reconciler-B6vJHxtX.js → orphan-proposed-reconciler-DfqHZftT.js} +23 -22
  210. package/server/package-lock.json +8 -8
  211. package/server/package.json +1 -1
  212. package/server/{pan-dir-DMzF5wne.js → pan-dir-DhgKfO86.js} +21 -6
  213. package/server/{paths-sJBSb7Ul.js → paths-BUuhi6jM.js} +17 -17
  214. package/server/{pending-lifecycle-claim-DilzGfgk.js → pending-lifecycle-claim-DJlA1rTR.js} +2 -2
  215. package/server/{persistent-logger-H_VjuOu7.js → persistent-logger-s8cbpFNV.js} +2 -2
  216. package/server/{pickup-DWhqzliO.js → pickup-2AxtB3dW.js} +1 -1
  217. package/server/{pipeline-membership-C88VBnhJ.js → pipeline-membership-2_okL5bm.js} +1 -1
  218. package/server/{pipeline-membership-D9SBvItj.js → pipeline-membership-Dqv6_0ig.js} +1 -1
  219. package/server/{pipeline-membership-gather-4eR-7Tqy.js → pipeline-membership-gather-4F1-tXKI.js} +1 -1
  220. package/server/{pipeline-membership-gather-CeVGnNJ2.js → pipeline-membership-gather-CtJ_7aGf.js} +149 -17
  221. package/server/{pipeline-notifier-DT6xLFao.js → pipeline-notifier-CO9rxJgB.js} +1 -1
  222. package/server/{pipeline-notifier-D0ALV6Nw.js → pipeline-notifier-DDfVBJhJ.js} +2 -2
  223. package/server/{post-merge-lifecycle-worker-8HIeS_J6.js → post-merge-lifecycle-worker-DmSOkeNp.js} +3 -3
  224. package/server/{project-pipelines-9SKt2bEc.js → project-pipelines-72WE8GVK.js} +2 -2
  225. package/server/{project-repos-B5pIphKg.js → project-repos-BAqDwtvi.js} +16 -11
  226. package/server/project-repos-Df90Zw7Y.js +3 -0
  227. package/server/projects-WqMWCdpa.js +3 -0
  228. package/server/{prompts-CgzMBvQF.js → prompts-XkL10m8M.js} +2 -2
  229. package/server/{providers-BJQSnAAp.js → providers-ClGPGkQ8.js} +15 -12
  230. package/server/providers-DFUOed8u.js +3 -0
  231. package/server/public/assets/{chunk-BO2N2NFS-D_pGACYN.js → chunk-BO2N2NFS-CeQUdPxr.js} +4 -4
  232. package/server/public/assets/{diagram-OG6HWLK6-BO6fe3hH.js → diagram-OG6HWLK6-B7rgk4yT.js} +1 -1
  233. package/server/public/assets/{dist-5zingMiA.js → dist-2RPazfXY.js} +3 -3
  234. package/server/public/assets/{dist-CVxhbI2E.js → dist-B9NInrVZ.js} +1 -1
  235. package/server/public/assets/{ganttDiagram-6RSMTGT7-Bgj4A7kp.js → ganttDiagram-6RSMTGT7-Bxp0gV14.js} +1 -1
  236. package/server/public/assets/{highlighted-body-OFNGDK62-DNPK7_cm.js → highlighted-body-OFNGDK62-CzoRTVlC.js} +1 -1
  237. package/server/public/assets/index-Cml-kHo6.css +1 -0
  238. package/server/public/assets/{index-DEpY-D1O.js → index-CvN8cEgs.js} +216 -215
  239. package/server/public/assets/{linear-BB0jQT16.js → linear-CFEEl3ND.js} +1 -1
  240. package/server/public/assets/mermaid-GHXKKRXX-CpV7nCBM.js +1 -0
  241. package/server/public/assets/{pieDiagram-4H26LBE5-DeGIzzpZ.js → pieDiagram-4H26LBE5-BeR8R0cr.js} +1 -1
  242. package/server/public/assets/{prod-XBLvikex.js → prod-CYjzjCrn.js} +4 -4
  243. package/server/public/assets/{quadrantDiagram-W4KKPZXB-BV9SLeWz.js → quadrantDiagram-W4KKPZXB-BpcTkFuW.js} +1 -1
  244. package/server/public/assets/{sankeyDiagram-5OEKKPKP-Dwja0gj8.js → sankeyDiagram-5OEKKPKP-Bx2ETEV5.js} +1 -1
  245. package/server/public/assets/{xychartDiagram-2RQKCTM6-DCB4qvfw.js → xychartDiagram-2RQKCTM6-BKgEAFaj.js} +1 -1
  246. package/server/public/index.html +2 -2
  247. package/server/{pull-requests-7BgLDsIo.js → pull-requests-B-KrUph5.js} +3 -3
  248. package/server/{pull-requests-Dq0y6IxE.js → pull-requests-DK5k92B4.js} +1 -1
  249. package/server/{queries-C-MUZaIy.js → queries-DVpl1vsU.js} +1212 -193
  250. package/server/{rally-CPysR4T_.js → rally-DbE561hD.js} +3 -3
  251. package/server/rally-O_st_X7n.js +3 -0
  252. package/server/{rally-api-8Ptlp2os.js → rally-api-CZLeEd2C.js} +2 -2
  253. package/server/{rally-api-CgosKdKL.js → rally-api-DaHtn5QN.js} +1 -1
  254. package/server/{rally-client-CCX0hADj.js → rally-client-C-MAl8ur.js} +1 -1
  255. package/server/{rally-client-iYMHWQD7.js → rally-client-Ch3zRsBX.js} +5 -5
  256. package/server/{reap-terminal-sessions-Qf-9LVQc.js → reap-terminal-sessions-C1n0ALRb.js} +2 -2
  257. package/server/{reap-terminal-sessions-4Xg9NGA8.js → reap-terminal-sessions-DegFS2p1.js} +2 -2
  258. package/server/{rebuild-stack-CMdgaylx.js → rebuild-stack-C9Li44A3.js} +20 -10
  259. package/server/{rebuild-stack-DqcOVmJO.js → rebuild-stack-qC0jCNm6.js} +2 -2
  260. package/server/{reconstruct-cache-CMZJ_Vjq.js → reconstruct-cache-BHyiAg02.js} +7 -7
  261. package/server/record-aVzu-LGm.js +3 -0
  262. package/server/record-update-CZh46a2f.js +617 -0
  263. package/server/{record-update-DhI7eySG.js → record-update-DtdJK2Iw.js} +1 -1
  264. package/server/recovery-trip-CSNWSLDn.js +77 -0
  265. package/server/recovery-trip-_16hFKv4.js +3 -0
  266. package/server/{release-engine-B2X9AfFC.js → release-engine-Be5MX5GP.js} +5 -5
  267. package/server/{release-set-G4XKyQ8K.js → release-set-DJv_O6PS.js} +3 -3
  268. package/server/{remote-BXarMvqf.js → remote-BMM3uH2J.js} +3 -3
  269. package/server/{remote-CUhyqjXk.js → remote-C0xVTHA5.js} +3 -3
  270. package/server/{remote-agents-CLZB3Coc.js → remote-agents-BIIoc5pD.js} +1 -1
  271. package/server/{remote-agents-Bba-MgSA.js → remote-agents-EUiZ26bj.js} +7 -7
  272. package/server/{remote-completion-CwAp79EC.js → remote-completion-BS4tJUn8.js} +13 -13
  273. package/server/resolver-BvHd6RE4.js +163 -0
  274. package/server/resume-9thEqAQR.js +3 -0
  275. package/server/{review-agent--pOptAEV.js → review-agent-BHGaBoBu.js} +29 -29
  276. package/server/{review-agent-BTCNkq2h.js → review-agent-CD3RQ-tc.js} +1 -1
  277. package/server/{review-artifacts-BNmw8dWE.js → review-artifacts-DyhajWso.js} +6 -6
  278. package/server/{review-context-DFxYOOJW.js → review-context-B-dlsPnx.js} +9 -9
  279. package/server/{review-convoy-liveness-BgU_1jJf.js → review-convoy-liveness-D7M-s_nS.js} +2 -2
  280. package/server/{review-status-Dma9SFaN.js → review-status-B6wYcOtP.js} +1 -1
  281. package/server/{review-status-CGvlA4o_.js → review-status-CKLk5aZ-.js} +308 -58
  282. package/server/{review-status-emit-DURrmGYX.js → review-status-emit-CJ7UmEVU.js} +3 -3
  283. package/server/{review-status-enrichment-8NiNXi5W.js → review-status-enrichment-DJRgGX7-.js} +3 -3
  284. package/server/review-status-limits-4EJDCGHO.js +7 -0
  285. package/server/{review-status-source-DIk1JSow.js → review-status-source-7nU3Z2wL.js} +1 -1
  286. package/server/{review-status-source-BLx_1siH.js → review-status-source-BsDYGfyv.js} +1 -1
  287. package/server/{review-status-sync-muT-EBp2.js → review-status-sync-BLssMTEW.js} +1 -1
  288. package/server/{review-status-sync-0GxOqeqF.js → review-status-sync-BxBeHRde.js} +35 -11
  289. package/server/{review-verdict-feedback-xJNdqBnX.js → review-verdict-feedback-5jWuzgpc.js} +90 -16
  290. package/server/{review-verdict-feedback-HwF6ODFy.js → review-verdict-feedback-HRY9P4bN.js} +1 -1
  291. package/server/{rollup-BQaol5TX.js → rollup-BGIrCEkU.js} +79 -44
  292. package/server/rollup-CZB4UL9q.js +3 -0
  293. package/server/{scanner-C-D2cFdX.js → scanner-DydjXPrz.js} +16 -9
  294. package/server/search-DdtIjAiu.js +395 -0
  295. package/server/{sequence-io-Bmf1EZM5.js → sequence-io-Fw-cLyDs.js} +4 -4
  296. package/server/{sequencer-agent-CigMyKh2.js → sequencer-agent-BcpGMt5x.js} +15 -10
  297. package/server/server.js +1258 -438
  298. package/server/{service-CD0DvFvD.js → service-BFFkGsG4.js} +58 -58
  299. package/server/{session-fork-B6cQ5eya.js → session-fork-D0V-3e5P.js} +2 -2
  300. package/server/{session-history-3ON_IJjm.js → session-history-Bta5l9jY.js} +5 -5
  301. package/server/{settings-PilbFZAM.js → settings-Ce8B1daF.js} +2 -2
  302. package/server/{settings-VN0qOh4U.js → settings-E3FnEIUx.js} +3 -3
  303. package/server/settings-eOOJpxi_.js +2 -0
  304. package/server/{shadow-engineering-DXvx77oE.js → shadow-engineering-Mt9nJO4i.js} +3 -3
  305. package/server/{shadow-state-CZBp7pwq.js → shadow-state-Bzj_AZCV.js} +1 -1
  306. package/server/{shadow-state-BBk_zacw.js → shadow-state-DrkhoVSx.js} +2 -2
  307. package/server/{shadow-utils-DdZ05AJS.js → shadow-utils-H1GfqP06.js} +2 -2
  308. package/server/{ship-log-7kJfjUX2.js → ship-log-CFUIo4PR.js} +1 -1
  309. package/server/{smart-compaction-8fA5k5XN.js → smart-compaction-DSTq-Wua.js} +1 -1
  310. package/server/{smart-compaction-ByhL9cRS.js → smart-compaction-Hzp3KCJX.js} +7 -7
  311. package/server/{spawn-planning-session-vLUJoFjy.js → spawn-planning-session-C0uSA2SL.js} +2 -2
  312. package/server/{spawn-planning-session-pcF-YeFE.js → spawn-planning-session-DN4son31.js} +23 -21
  313. package/server/{specialist-completion-B07XjWD2.js → specialist-completion-Cf6tpIh1.js} +1 -1
  314. package/server/{specialist-context-DJ-zFyL3.js → specialist-context-DEUEkjIQ.js} +5 -5
  315. package/server/{specialist-handoff-logger-aKSxbIgD.js → specialist-handoff-logger-D_LmQDj3.js} +2 -2
  316. package/server/{specialist-logs-Dae-n52_.js → specialist-logs-7Ynue0R7.js} +3 -3
  317. package/server/{specialists-KR3pKulN.js → specialists-CQwBEGlD.js} +1 -1
  318. package/server/{specialists-6PWdtWcg.js → specialists-DAjPgYs_.js} +504 -238
  319. package/server/{specialists-DUiExaxb.js → specialists-Hr6iW9fU.js} +18 -18
  320. package/server/{specialists-Bz-wFT7R.js → specialists-MOoeB4A8.js} +1 -1
  321. package/server/specs-Dl88cbKY.js +3 -0
  322. package/server/{src-B948bGVR.js → src-BYdwL_n-.js} +668 -64
  323. package/server/{src-vHy2-oCv.js → src-DQnkPN2i.js} +3 -3
  324. package/server/{src-rac0Mepv.js → src-DhfDV0o4.js} +6 -6
  325. package/server/{stack-health-DqLTiEu4.js → stack-health-D_iKwNRg.js} +107 -16
  326. package/server/stack-health-deVSdDwn.js +3 -0
  327. package/server/{stale-task-claims-Cab_Fo_Z.js → stale-task-claims-BYJGqhLI.js} +5 -5
  328. package/server/{staleness-CGTZyp6V.js → staleness-CopBDKnA.js} +1 -1
  329. package/server/{staleness-C-a5rBxF.js → staleness-D8WeMUHd.js} +1 -1
  330. package/server/{state-home-722Dkx92.js → state-home-DjN8qduI.js} +24 -3
  331. package/server/{state-mapping-CybR81Uf.js → state-mapping-DlM7OYRW.js} +1 -1
  332. package/server/{state-migrate-2u8wIpoL.js → state-migrate-a2p1gtD7.js} +4 -4
  333. package/server/state-mirror-Cv_XgvT5.js +121 -0
  334. package/server/{stuck-remediation-r1TJu68G.js → stuck-remediation-CXJX_kki.js} +1 -1
  335. package/server/{stuck-remediation-CC6q3eqQ.js → stuck-remediation-CbCRSz1v.js} +31 -732
  336. package/server/{substrate-bug-weights-service-CzIyyWFT.js → substrate-bug-weights-service-DxpopNd9.js} +3 -3
  337. package/server/{summary-fork-BqgmgPDt.js → summary-fork-B61fjRJn.js} +2 -2
  338. package/server/{summary-fork-Df2WFijM.js → summary-fork-B9pszUJN.js} +91 -10
  339. package/server/supervisor/{injection-budget-Cg_KIb3o.js → injection-budget-Ar7hgyJq.js} +1 -1
  340. package/server/supervisor/pty-supervisor.js +12 -3
  341. package/server/supervisor/{pty-token-BbjwEUUM.js → pty-token-CXCFU0Z8.js} +1 -1
  342. package/server/{supervisor-BxqSpjcN.js → supervisor-BvnxbuuF.js} +6 -4
  343. package/server/supervisor-C69kpqvd.js +2 -0
  344. package/server/{swarm-readiness-DfFxa9-n.js → swarm-readiness-vTw1kqGa.js} +3 -3
  345. package/server/{system-prerequisites-ICLSkhhZ.js → system-prerequisites-LLzTEqsK.js} +3 -3
  346. package/server/{teardown-workspace-DRdi_CPa.js → teardown-workspace-CqKKVJr1.js} +15 -15
  347. package/server/{test-agent-queue-A_-p-i0I.js → test-agent-queue-CWMq7oyG.js} +8 -7
  348. package/server/{test-verdict-BHgTAwIG.js → test-verdict-NdtgRBuA.js} +1 -1
  349. package/server/{test-verdict-C4i9aqEP.js → test-verdict-diIWE6hz.js} +15 -3
  350. package/server/{tldr-daemon-CvWXBhX1.js → tldr-daemon-B1Jhrtc8.js} +1 -1
  351. package/server/{tldr-daemon-wvsU6bKv.js → tldr-daemon-Bpls1CJB.js} +2 -2
  352. package/server/{tmux-CfDHob9M.js → tmux-CImZaX4q.js} +10 -16
  353. package/server/tmux-Cjpx8L8u.js +4 -0
  354. package/server/{token-DrxwytsZ.js → token-Bgpjo3tE.js} +2 -2
  355. package/server/token-util-BsjFll-k.js +3 -0
  356. package/server/{token-util-B48BlCba.js → token-util-BymbpkJp.js} +1 -1
  357. package/server/{tracker-config-BcPMElRB.js → tracker-config-4DaKVTfc.js} +2 -2
  358. package/server/{tracker-utils-CJ6BHjcD.js → tracker-utils-BDeAXC-q.js} +2 -2
  359. package/server/{traefik-connect-DZ6nMYMj.js → traefik-connect-CC5FyxYj.js} +1 -1
  360. package/server/{tunnel-Bp-dRHZz.js → tunnel-CDWkeceJ.js} +1 -1
  361. package/server/{tunnel-DUbUPElU.js → tunnel-CPf5M-Pc.js} +3 -3
  362. package/server/{typed-errors-DyjseiB6.js → typed-errors-9K7Dq_Vn.js} +1 -1
  363. package/server/{typed-errors-CKeoDdU3.js → typed-errors-DrS5fb5z.js} +1 -1
  364. package/server/{types-Cm5ASJbq.js → types-DzlUKiuf.js} +4 -3
  365. package/server/{types-Di8wdakq.js → types-kI9ik8XO.js} +1 -1
  366. package/server/{uat-promote-verification-CoJuh7XO.js → uat-promote-verification-c_pxoxEc.js} +5 -5
  367. package/server/{uat-train-4Q0k06CQ.js → uat-train-CWGxBdJO.js} +0 -0
  368. package/server/{uat-train-Dewoatps.js → uat-train-CfCYd2ve.js} +1 -1
  369. package/server/{validate-B0C8p66t.js → validate-f3ItVCfm.js} +3 -3
  370. package/server/{validation-hVOwQk8T.js → validation-5G_wQtea.js} +1 -1
  371. package/server/{validation-B_kIRfNe.js → validation-7tSiCM82.js} +4 -4
  372. package/server/{verification-artifact-BxlxTiYK.js → verification-artifact-9h9dH8uX.js} +1 -1
  373. package/server/{verification-artifact-D70AtckY.js → verification-artifact-C_4WJnf6.js} +1 -1
  374. package/server/{verification-runner-Bc3cJvpC.js → verification-runner-BV5F6wrA.js} +1 -1
  375. package/server/{verification-runner-KZTz6u72.js → verification-runner-D58KmBhK.js} +18 -38
  376. package/server/{vtt-parser-CE_i3Bcw.js → vtt-parser-2iT9OHa9.js} +1 -1
  377. package/server/{work-agent-prompt-ByrPAzOy.js → work-agent-prompt-D03s4DD1.js} +9 -9
  378. package/server/{workflows-D0vP1WrK.js → workflows-BMBwLYPV.js} +281 -98
  379. package/server/workflows-BOmWGpIh.js +2 -0
  380. package/server/{workspace-DQkRPLlQ.js → workspace-BgflNCH0.js} +3 -3
  381. package/server/{workspace-COWvdibH.js → workspace-Cn9ywfSW.js} +1 -1
  382. package/server/{workspace-anchor-drift-pwz23TI1.js → workspace-anchor-drift-C8Fy3shi.js} +1 -1
  383. package/server/{workspace-anchor-drift-DXYIAHzr.js → workspace-anchor-drift-CMiNncwq.js} +5 -8
  384. package/server/{workspace-config-BdZM4PvZ.js → workspace-config-aUc2nIz6.js} +1 -1
  385. package/server/{workspace-manager-BPgTrG66.js → workspace-manager-Bem7ZBs9.js} +521 -292
  386. package/server/workspace-manager-C0CpNh3t.js +3 -0
  387. package/server/{workspace-metadata-CdjzAP8x.js → workspace-metadata-C5iSlPRo.js} +1 -1
  388. package/server/{workspace-metadata-DkO_iTLo.js → workspace-metadata-UKmTYmDQ.js} +2 -2
  389. package/server/{workspaces-CRBJikLp.js → workspaces-DqxgwDZ8.js} +143 -113
  390. package/sync-sources/hooks/notification-hook +12 -1
  391. package/sync-sources/hooks/pan-hook-lib.sh +226 -0
  392. package/sync-sources/hooks/session-start-hook +31 -4
  393. package/sync-sources/hooks/work-agent-stop-hook +23 -1
  394. package/sync-sources/skills/pan-memory/SKILL.md +19 -3
  395. package/sync-sources/skills/pan-projects/SKILL.md +9 -0
  396. package/sync-sources/skills/pan-restart/SKILL.md +26 -7
  397. package/sync-sources/skills/pan-workspace/SKILL.md +77 -0
  398. package/server/activity-logger-CMthG6Vd.js +0 -3
  399. package/server/agent-state-CYXJVG72.js +0 -3
  400. package/server/agents-ePFVoZbu.js +0 -3
  401. package/server/archive-planning-B2XplFzT.js +0 -2
  402. package/server/cli-CjOCSnfj.js +0 -3
  403. package/server/deacon-swarm-B1XkIvfr.js +0 -2
  404. package/server/delivery-BX9HR4wQ.js +0 -3
  405. package/server/dist-B3YPQa5A.js +0 -3
  406. package/server/event-store-5UKzh9Jf.js +0 -3
  407. package/server/forge-B5o319qI.js +0 -3
  408. package/server/fts-db-IVc4_M3f.js +0 -146
  409. package/server/hume-VUCNbTgn.js +0 -3
  410. package/server/inspect-agent-CUwVmr2h.js +0 -2
  411. package/server/merge-ops-1abz6O_P.js +0 -2
  412. package/server/merge-rebase-CJJVAJuz.js +0 -2
  413. package/server/node_modules/brace-expansion/.tap/coverage/8b906b8c-e21f-40b5-8c0d-214d8c2682c5.json +0 -757
  414. package/server/node_modules/brace-expansion/.tap/processinfo/8b906b8c-e21f-40b5-8c0d-214d8c2682c5.json +0 -719
  415. package/server/node_modules/brace-expansion/ADVISORY-CVE-2026-14257.md +0 -107
  416. package/server/node_modules/brace-expansion/dist/commonjs/index.d.ts +0 -8
  417. package/server/node_modules/brace-expansion/dist/commonjs/index.d.ts.map +0 -1
  418. package/server/node_modules/brace-expansion/dist/commonjs/index.js +0 -263
  419. package/server/node_modules/brace-expansion/dist/commonjs/index.js.map +0 -1
  420. package/server/node_modules/brace-expansion/dist/commonjs/package.json +0 -3
  421. package/server/node_modules/brace-expansion/dist/esm/index.d.ts +0 -8
  422. package/server/node_modules/brace-expansion/dist/esm/index.d.ts.map +0 -1
  423. package/server/node_modules/brace-expansion/dist/esm/index.js +0 -259
  424. package/server/node_modules/brace-expansion/dist/esm/index.js.map +0 -1
  425. package/server/node_modules/brace-expansion/dist/esm/package.json +0 -3
  426. package/server/project-repos-DPjOdfPa.js +0 -3
  427. package/server/projects-_n3Zui6K.js +0 -3
  428. package/server/providers-BI1mOBQ4.js +0 -3
  429. package/server/public/assets/index-Ddkcz3WT.css +0 -1
  430. package/server/public/assets/mermaid-GHXKKRXX-BzPfaQJ1.js +0 -1
  431. package/server/rally-D_VW4bJv.js +0 -3
  432. package/server/record-BTwWhtBb.js +0 -3
  433. package/server/record-update-DaOKS7Wb.js +0 -277
  434. package/server/recovery-trip-DDH-02ng.js +0 -44
  435. package/server/resume-mOREjlYu.js +0 -3
  436. package/server/rollup-BR4t_wck.js +0 -3
  437. package/server/settings-CVmWiJ-r.js +0 -2
  438. package/server/specs--enInima.js +0 -3
  439. package/server/stack-health-BikqHSjn.js +0 -3
  440. package/server/supervisor-B4anCCSm.js +0 -2
  441. package/server/tmux-Ctk6RV5l.js +0 -3
  442. package/server/token-util-D411CAq9.js +0 -3
  443. package/server/workflows-DtDX08ed.js +0 -2
  444. package/server/workspace-manager-C1F3XsnS.js +0 -3
@@ -1,20 +1,25 @@
1
1
  import { n as __esmMin } from "./rolldown-runtime-DNCzzKnI.js";
2
- import { Br as CACHE_RULES_DIR, Fr as init_errors, Gn as init_projects, Qr as SYNC_SOURCES, Tr as FsError, Zr as SKILLS_DIR, f as loadConfigSync, jr as ProcessSpawnError, li as init_paths, t as init_config_yaml, zr as CACHE_AGENTS_DIR } from "./config-yaml-CxdwhAIA.js";
3
- import { a as PAN_DIRNAME, c as PAN_SESSIONS_FILENAME, i as PAN_CONTINUE_FILENAME, n as PAN_CONTEXT_FILENAME, s as PAN_FEEDBACK_DIRNAME } from "./types-Cm5ASJbq.js";
4
- import { t as init_pan_dir } from "./pan-dir-DMzF5wne.js";
5
- import { n as init_workspace_config, r as replacePlaceholdersSync, t as getDefaultWorkspaceConfigSync } from "./workspace-config-BdZM4PvZ.js";
6
- import { n as init_tunnel, r as removeTunnelIngress, t as addTunnelIngress } from "./tunnel-DUbUPElU.js";
7
- import { i as init_hume, n as createHumeConfig, r as deleteHumeConfig } from "./hume-DXNiu6nQ.js";
8
- import { a as renderDevcontainerSync, i as processTemplatesSync, n as createWorkspacePlaceholdersSync, o as sanitizeComposeFileSync, r as init_devcontainer_renderer, t as DEVCONTAINER_DIRNAME } from "./devcontainer-renderer-BUOIlfgD.js";
9
- import { n as init_docker, r as stopWorkspaceDockerPromise, t as getContainersReferencingWorkspacePathPromise } from "./docker-BJzlkqYB.js";
2
+ import { Ar as FsError, Gr as CACHE_AGENTS_DIR, Kr as CACHE_RULES_DIR, Lr as ProcessSpawnError, Vr as init_errors, cn as init_projects, f as loadConfigSync, fn as listProjectsSync, hi as init_paths, ii as SYNC_SOURCES, ri as SKILLS_DIR, t as init_config_yaml } from "./config-yaml-BSCqwmX0.js";
3
+ import { d as getOverdeckDatabaseSync, f as init_infra } from "./infra-CTrmVqc_.js";
4
+ import { a as getWorkspaceForIssue, i as getWorkspaceById, n as getProjectByKey, o as init_resolver, r as getProjectByPath, s as listPinnedDocs, t as getMainWorkspace } from "./resolver-BvHd6RE4.js";
5
+ import { i as init_paths$1, m as resolveWorkspaceMemoryRoot, r as ensureParentDir } from "./paths-BUuhi6jM.js";
6
+ import { a as PAN_DIRNAME, c as PAN_SESSIONS_FILENAME, i as PAN_CONTINUE_FILENAME, n as PAN_CONTEXT_FILENAME, s as PAN_FEEDBACK_DIRNAME } from "./types-DzlUKiuf.js";
7
+ import { t as init_pan_dir } from "./pan-dir-DhgKfO86.js";
8
+ import { n as init_workspace_config, r as replacePlaceholdersSync, t as getDefaultWorkspaceConfigSync } from "./workspace-config-aUc2nIz6.js";
9
+ import { n as init_tunnel, r as removeTunnelIngress, t as addTunnelIngress } from "./tunnel-CPf5M-Pc.js";
10
+ import { i as init_hume, n as createHumeConfig, r as deleteHumeConfig } from "./hume-DrZEGpqc.js";
11
+ import { r as unmirrorPin, t as init_state_mirror } from "./state-mirror-Cv_XgvT5.js";
12
+ import { a as renderDevcontainerSync, i as processTemplatesSync, n as createWorkspacePlaceholdersSync, o as sanitizeComposeFileSync, r as init_devcontainer_renderer, t as DEVCONTAINER_DIRNAME } from "./devcontainer-renderer-B-o68Z5B.js";
13
+ import { n as init_docker, r as stopWorkspaceDockerPromise, t as getContainersReferencingWorkspacePathPromise } from "./docker-meuLKLzV.js";
10
14
  import { join } from "node:path";
11
15
  import { Effect } from "effect";
12
16
  import { chmodSync, copyFileSync, existsSync, lstatSync, mkdirSync, readFileSync, readdirSync, realpathSync, renameSync, rmSync, statSync, symlinkSync, unlinkSync, writeFileSync } from "fs";
13
17
  import { basename as basename$1, dirname as dirname$1, extname as extname$1, join as join$1, relative as relative$1, resolve as resolve$1 } from "path";
14
18
  import { homedir, platform } from "os";
15
19
  import { existsSync as existsSync$1, mkdirSync as mkdirSync$1, readdirSync as readdirSync$1, readlinkSync, renameSync as renameSync$1, statSync as statSync$1, symlinkSync as symlinkSync$1 } from "node:fs";
16
- import { createHash } from "crypto";
17
- import "fs/promises";
20
+ import { createHash, randomUUID } from "crypto";
21
+ import { readFile, rename, writeFile } from "fs/promises";
22
+ import { randomUUID as randomUUID$1 } from "node:crypto";
18
23
  import { exec, execFile } from "child_process";
19
24
  import { promisify } from "util";
20
25
  //#region ../../lib/workspace-manager/migration.ts
@@ -589,6 +594,26 @@ function relocateVenvScripts(sourceVenv, destVenv) {
589
594
  } catch {}
590
595
  }
591
596
  }
597
+ /**
598
+ * Keep a generated hooks directory that lives inside the worktree out of
599
+ * `git status`. With husky, `core.hooksPath` is `.husky/_` — a tracked-repo
600
+ * path husky self-ignores by writing a `*` .gitignore into it on install.
601
+ * `installPreRebaseHook` creates that directory itself in a fresh worktree,
602
+ * long before `prepare: husky` ever runs, so without this the generated guard
603
+ * lands as `?? .husky/_/pre-rebase` and every new workspace is born dirty —
604
+ * which 409s the planning→work auto-handoff (PAN-3266).
605
+ *
606
+ * Directories under `.git/` need nothing: git never reports them.
607
+ */
608
+ function ensureGeneratedHooksDirIsIgnored(targetPath, hooksDir) {
609
+ const relativeDir = relative$1(targetPath, hooksDir).replace(/\\/g, "/");
610
+ if (!relativeDir || relativeDir.startsWith("..") || relativeDir === ".git" || relativeDir.startsWith(".git/")) return;
611
+ const ignorePath = join$1(hooksDir, ".gitignore");
612
+ if (existsSync(ignorePath)) return;
613
+ try {
614
+ writeFileSync(ignorePath, "*\n", "utf-8");
615
+ } catch {}
616
+ }
592
617
  /** Install the agent-only rebase guard in Git's configured hooks directory. */
593
618
  async function installPreRebaseHook(targetPath) {
594
619
  const { stdout } = await execAsync$2("git rev-parse --git-path hooks", {
@@ -598,6 +623,7 @@ async function installPreRebaseHook(targetPath) {
598
623
  const hooksDir = resolve$1(targetPath, stdout.trim());
599
624
  const hookPath = join$1(hooksDir, "pre-rebase");
600
625
  mkdirSync(hooksDir, { recursive: true });
626
+ ensureGeneratedHooksDirIsIgnored(targetPath, hooksDir);
601
627
  const originalHookPath = `${hookPath}${PRE_REBASE_ORIGINAL_SUFFIX}`;
602
628
  const existingHook = existsSync(hookPath) ? readFileSync(hookPath, "utf-8") : "";
603
629
  if (!existingHook.includes(PRE_REBASE_HOOK_MARKER)) {
@@ -844,6 +870,172 @@ var init_worktree_ops = __esmMin((() => {
844
870
  ]);
845
871
  }));
846
872
  //#endregion
873
+ //#region ../../lib/memory/identity-record.ts
874
+ /**
875
+ * Workspace identity mirror (PAN-1990, memory-paths-rekey).
876
+ *
877
+ * Memory storage is keyed by workspaceId (resolveWorkspaceMemoryRoot), which
878
+ * is an opaque UUID with no human-readable trace back to the workspace it
879
+ * belonged to if the overdeck.db row is ever lost. metadata.json at the
880
+ * workspace's memory root is that trace: a best-effort recovery hint, not
881
+ * canonical state. The workspaces table row remains the source of truth.
882
+ */
883
+ function resolveWorkspaceIdentityPath(projectId, workspaceId) {
884
+ return join$1(resolveWorkspaceMemoryRoot(projectId, workspaceId), "metadata.json");
885
+ }
886
+ /** Write (or merge over) the identity fields at the workspace's memory-home metadata.json. */
887
+ async function writeWorkspaceIdentity(row) {
888
+ const path = resolveWorkspaceIdentityPath(row.projectId, row.id);
889
+ await ensureParentDir(path);
890
+ const merged = {
891
+ ...await readWorkspaceIdentity(path),
892
+ id: row.id,
893
+ projectId: row.projectId,
894
+ kind: row.kind,
895
+ name: row.name,
896
+ path: row.path,
897
+ branchName: row.branchName,
898
+ parentBranch: row.parentBranch,
899
+ issueId: row.issueId,
900
+ createdAt: row.createdAt
901
+ };
902
+ const tempPath = join$1(dirname$1(path), `.${randomUUID()}.tmp`);
903
+ await writeFile(tempPath, `${JSON.stringify(merged, null, 2)}\n`, "utf8");
904
+ await rename(tempPath, path);
905
+ return path;
906
+ }
907
+ /** Parse a workspace's metadata.json for rebuild. Returns null if missing or unreadable. */
908
+ async function readWorkspaceIdentity(path) {
909
+ try {
910
+ const raw = await readFile(path, "utf8");
911
+ return JSON.parse(raw);
912
+ } catch {
913
+ return null;
914
+ }
915
+ }
916
+ var init_identity_record = __esmMin((() => {
917
+ init_paths$1();
918
+ }));
919
+ //#endregion
920
+ //#region ../../lib/workspaces/writer.ts
921
+ /**
922
+ * Workspaces/projects write door (PAN-1990).
923
+ *
924
+ * The ONLY module that INSERT/UPDATE/DELETEs the projects/workspaces/
925
+ * project_targets/pinned_docs tables. See docs/PIPELINE-MEMBERSHIP.md's
926
+ * two-doors tenet — every write to these tables goes through this writer.
927
+ *
928
+ * Identity-record mirroring into a workspace's memory-home metadata.json is a
929
+ * best-effort recovery hint, not canonical state (the workspaces table row
930
+ * remains the source of truth) — createWorkspace/archiveWorkspace are async
931
+ * only to await that mirror write; the SQLite row write itself stays sync.
932
+ */
933
+ /** Upsert a projects.yaml entry into the projects table, keyed by its yaml key. */
934
+ function upsertProjectFromConfig(key, config) {
935
+ const db = getOverdeckDatabaseSync();
936
+ const now = Date.now();
937
+ if (getProjectByKey(key)) {
938
+ db.prepare(`UPDATE projects SET name = ?, primary_path = ? WHERE id = ?`).run(config.name, config.path, key);
939
+ return;
940
+ }
941
+ db.prepare(`
942
+ INSERT INTO projects (id, name, primary_path, created_at, last_accessed_at, is_system)
943
+ VALUES (?, ?, ?, ?, ?, 0)
944
+ `).run(key, config.name, config.path, now, now);
945
+ }
946
+ /** Create a workspace row. Generates a fresh UUID and enforces main-singleton per project. */
947
+ async function createWorkspace$1(opts) {
948
+ const db = getOverdeckDatabaseSync();
949
+ if (opts.kind === "main" && getMainWorkspace(opts.projectId)) throw new Error(`Project ${opts.projectId} already has a main workspace`);
950
+ const id = opts.id ?? randomUUID$1();
951
+ const now = opts.createdAt ?? Date.now();
952
+ db.prepare(`
953
+ INSERT INTO workspaces (
954
+ id, project_id, kind, name, path, branch_name, parent_branch, parent_branch_guessed,
955
+ is_git_repository, issue_id, layout_config, is_favorite, is_archived, title,
956
+ created_at, last_accessed_at
957
+ ) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, NULL, 0, 0, ?, ?, ?)
958
+ `).run(id, opts.projectId, opts.kind, opts.name, opts.path, opts.branchName ?? null, opts.parentBranch ?? null, opts.parentBranchGuessed ? 1 : 0, opts.isGitRepository === false ? 0 : 1, opts.issueId ?? null, opts.title ?? null, now, now);
959
+ await writeWorkspaceIdentity({
960
+ id,
961
+ projectId: opts.projectId,
962
+ kind: opts.kind,
963
+ name: opts.name,
964
+ path: opts.path,
965
+ branchName: opts.branchName ?? null,
966
+ parentBranch: opts.parentBranch ?? null,
967
+ issueId: opts.issueId ?? null,
968
+ createdAt: now
969
+ }).catch(() => {});
970
+ return id;
971
+ }
972
+ function touchWorkspaceAccessed(id) {
973
+ getOverdeckDatabaseSync().prepare(`UPDATE workspaces SET last_accessed_at = ? WHERE id = ?`).run(Date.now(), id);
974
+ }
975
+ function updateWorkspaceLayout(id, layoutConfig) {
976
+ getOverdeckDatabaseSync().prepare(`UPDATE workspaces SET layout_config = ? WHERE id = ?`).run(layoutConfig, id);
977
+ }
978
+ function setWorkspaceFavorite(id, isFavorite) {
979
+ getOverdeckDatabaseSync().prepare(`UPDATE workspaces SET is_favorite = ? WHERE id = ?`).run(isFavorite ? 1 : 0, id);
980
+ }
981
+ async function archiveWorkspace(id) {
982
+ getOverdeckDatabaseSync().prepare(`UPDATE workspaces SET is_archived = 1 WHERE id = ?`).run(id);
983
+ const workspace = getWorkspaceById(id);
984
+ if (workspace) await writeWorkspaceIdentity({
985
+ id: workspace.id,
986
+ projectId: workspace.projectId,
987
+ kind: workspace.kind,
988
+ name: workspace.name,
989
+ path: workspace.path,
990
+ branchName: workspace.branchName,
991
+ parentBranch: workspace.parentBranch,
992
+ issueId: workspace.issueId,
993
+ createdAt: workspace.createdAt
994
+ }).catch(() => {});
995
+ }
996
+ function unarchiveWorkspace(id) {
997
+ getOverdeckDatabaseSync().prepare(`UPDATE workspaces SET is_archived = 0 WHERE id = ?`).run(id);
998
+ }
999
+ /**
1000
+ * Delete a non-main workspace row. Conversations attributed to it are
1001
+ * preserved with workspace_id set to NULL — never deleted. Workspace-scoped
1002
+ * pins are removed, including their committed overdeck-state mirror
1003
+ * descriptors (FR-10/FR-11 — the mirror is the durable representation, so a
1004
+ * pin row deleted here without unmirroring it would let a future recovery
1005
+ * from state resurrect a pin the workspace deletion was supposed to remove).
1006
+ * Project-scoped pins are untouched. Never touches JSONL transcripts or the
1007
+ * memory home (memory purge is a separate explicit flag on the CLI destroy
1008
+ * verb).
1009
+ *
1010
+ * Review fix (durability): the durable mirror is unmirrored FIRST, before
1011
+ * the SQLite rows are ever touched. If a state-door commit/push fails here,
1012
+ * the function throws and the workspace + pin rows are untouched — a caller
1013
+ * retry re-lists the same pins from the unharmed DB row and re-attempts.
1014
+ * Doing the DB delete first (the previous ordering) would forget the pin
1015
+ * list before the mirror cleanup could be retried, permanently stranding it.
1016
+ * unmirrorPin/removeMemoryStateMirror already no-op on an already-removed
1017
+ * target, so retrying an already-unmirrored pin is safe.
1018
+ */
1019
+ async function deleteWorkspace(id) {
1020
+ const db = getOverdeckDatabaseSync();
1021
+ const workspace = getWorkspaceById(id);
1022
+ if (!workspace) return;
1023
+ if (workspace.kind === "main") throw new Error(`Cannot delete the main workspace for project ${workspace.projectId}`);
1024
+ const workspacePins = listPinnedDocs("workspace", id);
1025
+ await Promise.all(workspacePins.map((pin) => unmirrorPin(workspace.projectId, "workspace", id, pin.docPath)));
1026
+ db.transaction(() => {
1027
+ db.prepare(`UPDATE conversations SET workspace_id = NULL WHERE workspace_id = ?`).run(id);
1028
+ db.prepare(`DELETE FROM pinned_docs WHERE scope = 'workspace' AND scope_id = ?`).run(id);
1029
+ db.prepare(`DELETE FROM workspaces WHERE id = ?`).run(id);
1030
+ })();
1031
+ }
1032
+ var init_writer = __esmMin((() => {
1033
+ init_infra();
1034
+ init_identity_record();
1035
+ init_state_mirror();
1036
+ init_resolver();
1037
+ }));
1038
+ //#endregion
847
1039
  //#region ../../lib/workspace-manager/create.ts
848
1040
  /**
849
1041
  * PAN-2386: ensure a polyrepo scaffold workspace has a .gitignore that excludes
@@ -959,317 +1151,351 @@ async function createWorkspacePromise(options) {
959
1151
  result.steps.push("[DRY RUN] Would create workspace at: " + workspacePath);
960
1152
  return result;
961
1153
  }
962
- let stagedMetadataPath = null;
963
- if (existsSync(workspacePath)) {
964
- stagedMetadataPath = stagePreWorktreeMetadataSync(workspacePath);
965
- if (stagedMetadataPath) result.steps.push("Staged pre-worktree .pan metadata");
966
- else {
967
- result.success = false;
968
- result.errors.push(`Workspace already exists at ${workspacePath}`);
969
- return result;
1154
+ const issueId = featureName.toUpperCase();
1155
+ let createdWorkspaceRowId = null;
1156
+ let worktreeCreated = false;
1157
+ if (!getWorkspaceForIssue(issueId)) {
1158
+ let project = getProjectByPath(projectConfig.path);
1159
+ if (!project) {
1160
+ const projectKey = listProjectsSync().find((p) => p.config.path === projectConfig.path)?.key;
1161
+ if (!projectKey) {
1162
+ result.success = false;
1163
+ result.errors.push(`No projects.yaml entry found for path ${projectConfig.path}; cannot create workspace row for ${issueId}.`);
1164
+ return result;
1165
+ }
1166
+ upsertProjectFromConfig(projectKey, projectConfig);
1167
+ project = getProjectByPath(projectConfig.path);
970
1168
  }
1169
+ createdWorkspaceRowId = await createWorkspace$1({
1170
+ projectId: project.id,
1171
+ kind: "issue",
1172
+ name: featureFolder,
1173
+ path: workspacePath,
1174
+ branchName: `feature/${featureName}`,
1175
+ issueId
1176
+ });
971
1177
  }
972
- const placeholders = createWorkspacePlaceholdersSync(projectConfig, featureName, workspacePath);
973
- progress("Creating git worktree", `feature/${featureName}`);
974
- if (workspaceConfig.type === "polyrepo" && workspaceConfig.repos) {
975
- mkdirSync(workspacePath, { recursive: true });
976
- result.steps.push("Created workspace directory");
977
- const reposToCreate = workspaceConfig.progressive && workspaceConfig.always_include ? workspaceConfig.repos.filter((r) => workspaceConfig.always_include.includes(r.name)) : workspaceConfig.repos;
978
- for (const repo of reposToCreate) {
979
- const rawRepoPath = join$1(projectConfig.path, repo.path);
980
- const repoPath = existsSync(rawRepoPath) ? realpathSync(rawRepoPath) : rawRepoPath;
981
- const targetPath = join$1(workspacePath, repo.name);
982
- if (repo.link_type === "symlink") try {
983
- symlinkSync(repoPath, targetPath);
984
- result.steps.push(`Created symlink for ${repo.name} (readonly, no feature branch)`);
985
- } catch (symlinkErr) {
986
- result.errors.push(`${repo.name}: ${symlinkErr.message}`);
1178
+ const outcome = await (async () => {
1179
+ let stagedMetadataPath = null;
1180
+ if (existsSync(workspacePath)) {
1181
+ stagedMetadataPath = stagePreWorktreeMetadataSync(workspacePath);
1182
+ if (stagedMetadataPath) result.steps.push("Staged pre-worktree .pan metadata");
1183
+ else {
987
1184
  result.success = false;
1185
+ result.errors.push(`Workspace already exists at ${workspacePath}`);
1186
+ return result;
988
1187
  }
989
- else {
990
- const branchName = `${repo.branch_prefix || "feature/"}${featureName}`;
991
- const defaultBranch = repo.default_branch || workspaceConfig.default_branch || "main";
992
- const worktreeResult = await createWorktree(repoPath, targetPath, branchName, defaultBranch);
993
- if (worktreeResult.success) result.steps.push(`Created worktree for ${repo.name}: ${branchName} (from ${defaultBranch})`);
994
- else {
995
- result.errors.push(`${repo.name}: ${worktreeResult.message}`);
1188
+ }
1189
+ const placeholders = createWorkspacePlaceholdersSync(projectConfig, featureName, workspacePath);
1190
+ progress("Creating git worktree", `feature/${featureName}`);
1191
+ if (workspaceConfig.type === "polyrepo" && workspaceConfig.repos) {
1192
+ mkdirSync(workspacePath, { recursive: true });
1193
+ result.steps.push("Created workspace directory");
1194
+ worktreeCreated = true;
1195
+ const reposToCreate = workspaceConfig.progressive && workspaceConfig.always_include ? workspaceConfig.repos.filter((r) => workspaceConfig.always_include.includes(r.name)) : workspaceConfig.repos;
1196
+ for (const repo of reposToCreate) {
1197
+ const rawRepoPath = join$1(projectConfig.path, repo.path);
1198
+ const repoPath = existsSync(rawRepoPath) ? realpathSync(rawRepoPath) : rawRepoPath;
1199
+ const targetPath = join$1(workspacePath, repo.name);
1200
+ if (repo.link_type === "symlink") try {
1201
+ symlinkSync(repoPath, targetPath);
1202
+ result.steps.push(`Created symlink for ${repo.name} (readonly, no feature branch)`);
1203
+ } catch (symlinkErr) {
1204
+ result.errors.push(`${repo.name}: ${symlinkErr.message}`);
996
1205
  result.success = false;
997
1206
  }
1207
+ else {
1208
+ const branchName = `${repo.branch_prefix || "feature/"}${featureName}`;
1209
+ const defaultBranch = repo.default_branch || workspaceConfig.default_branch || "main";
1210
+ const worktreeResult = await createWorktree(repoPath, targetPath, branchName, defaultBranch);
1211
+ if (worktreeResult.success) result.steps.push(`Created worktree for ${repo.name}: ${branchName} (from ${defaultBranch})`);
1212
+ else {
1213
+ result.errors.push(`${repo.name}: ${worktreeResult.message}`);
1214
+ result.success = false;
1215
+ }
1216
+ }
1217
+ }
1218
+ } else {
1219
+ const branchName = `feature/${featureName}`;
1220
+ const defaultBranch = workspaceConfig.default_branch || "main";
1221
+ const worktreeResult = await createWorktree(projectConfig.path, workspacePath, branchName, defaultBranch);
1222
+ if (worktreeResult.success) result.steps.push(`Created worktree: ${branchName} (from ${defaultBranch})`);
1223
+ else {
1224
+ result.errors.push(worktreeResult.message);
1225
+ result.success = false;
998
1226
  }
999
1227
  }
1000
- } else {
1001
- const branchName = `feature/${featureName}`;
1002
- const defaultBranch = workspaceConfig.default_branch || "main";
1003
- const worktreeResult = await createWorktree(projectConfig.path, workspacePath, branchName, defaultBranch);
1004
- if (worktreeResult.success) result.steps.push(`Created worktree: ${branchName} (from ${defaultBranch})`);
1005
- else {
1006
- result.errors.push(worktreeResult.message);
1007
- result.success = false;
1228
+ if (!result.success) {
1229
+ restorePreWorktreeMetadataSync(stagedMetadataPath, workspacePath);
1230
+ progress("Creating git worktree", "Worktree creation failed", "error");
1231
+ return result;
1008
1232
  }
1009
- }
1010
- if (!result.success) {
1233
+ worktreeCreated = true;
1011
1234
  restorePreWorktreeMetadataSync(stagedMetadataPath, workspacePath);
1012
- progress("Creating git worktree", "Worktree creation failed", "error");
1013
- return result;
1014
- }
1015
- restorePreWorktreeMetadataSync(stagedMetadataPath, workspacePath);
1016
- if (workspaceConfig.type === "polyrepo" && workspaceConfig.repos) try {
1017
- const { added, removed } = ensurePolyrepoWorkspaceGitignoreSync(workspacePath, workspaceConfig.repos);
1018
- if (added.length > 0 || removed.length > 0) {
1019
- result.steps.push(`Updated .gitignore for polyrepo workspace (${added.length} added, ${removed.length} removed)`);
1020
- const commitMessage = await commitPolyrepoWorkspaceGitignoreAsync(workspacePath);
1021
- if (commitMessage) result.steps.push(commitMessage);
1235
+ if (workspaceConfig.type === "polyrepo" && workspaceConfig.repos) try {
1236
+ const { added, removed } = ensurePolyrepoWorkspaceGitignoreSync(workspacePath, workspaceConfig.repos);
1237
+ if (added.length > 0 || removed.length > 0) {
1238
+ result.steps.push(`Updated .gitignore for polyrepo workspace (${added.length} added, ${removed.length} removed)`);
1239
+ const commitMessage = await commitPolyrepoWorkspaceGitignoreAsync(workspacePath);
1240
+ if (commitMessage) result.steps.push(commitMessage);
1241
+ }
1242
+ } catch (gitignoreErr) {
1243
+ result.steps.push(`Warning: could not create workspace .gitignore: ${gitignoreErr.message}`);
1022
1244
  }
1023
- } catch (gitignoreErr) {
1024
- result.steps.push(`Warning: could not create workspace .gitignore: ${gitignoreErr.message}`);
1025
- }
1026
- progress("Creating git worktree", "Worktree ready", "complete");
1027
- const resolvedWorkspace = resolve$1(workspacePath);
1028
- const resolvedPanDir = resolve$1(resolvedWorkspace, PAN_DIRNAME);
1029
- if (resolvedWorkspace.match(/\/workspaces\/feature-[a-z0-9-]+$/) && existsSync(join$1(resolvedWorkspace, ".git"))) {
1030
- if (resolvedPanDir === join$1(resolvedWorkspace, ".pan") && existsSync(resolvedPanDir)) {
1031
- for (const filePath of [
1032
- join$1(resolvedPanDir, PAN_CONTINUE_FILENAME),
1033
- join$1(resolvedPanDir, PAN_SESSIONS_FILENAME),
1034
- join$1(resolvedPanDir, PAN_CONTEXT_FILENAME)
1035
- ]) if (existsSync(filePath)) unlinkSync(filePath);
1036
- const feedbackDir = join$1(resolvedPanDir, PAN_FEEDBACK_DIRNAME);
1037
- if (existsSync(feedbackDir)) rmSync(feedbackDir, {
1038
- recursive: true,
1039
- force: true
1040
- });
1245
+ progress("Creating git worktree", "Worktree ready", "complete");
1246
+ const resolvedWorkspace = resolve$1(workspacePath);
1247
+ const resolvedPanDir = resolve$1(resolvedWorkspace, PAN_DIRNAME);
1248
+ if (resolvedWorkspace.match(/\/workspaces\/feature-[a-z0-9-]+$/) && existsSync(join$1(resolvedWorkspace, ".git"))) {
1249
+ if (resolvedPanDir === join$1(resolvedWorkspace, ".pan") && existsSync(resolvedPanDir)) {
1250
+ for (const filePath of [
1251
+ join$1(resolvedPanDir, PAN_CONTINUE_FILENAME),
1252
+ join$1(resolvedPanDir, PAN_SESSIONS_FILENAME),
1253
+ join$1(resolvedPanDir, PAN_CONTEXT_FILENAME)
1254
+ ]) if (existsSync(filePath)) unlinkSync(filePath);
1255
+ const feedbackDir = join$1(resolvedPanDir, PAN_FEEDBACK_DIRNAME);
1256
+ if (existsSync(feedbackDir)) rmSync(feedbackDir, {
1257
+ recursive: true,
1258
+ force: true
1259
+ });
1260
+ }
1261
+ result.steps.push("Cleared stale workspace-local .pan runtime state");
1041
1262
  }
1042
- result.steps.push("Cleared stale workspace-local .pan runtime state");
1043
- }
1044
- try {
1045
- ensurePanGitignoreSync(projectConfig.path);
1046
- result.steps.push("Verified runtime-only Overdeck and Claude Code sync paths are in .gitignore");
1047
- } catch (gitignoreErr) {
1048
- result.steps.push(`Warning: could not update .gitignore: ${gitignoreErr.message}`);
1049
- }
1050
- const devcontainerDir = join$1(workspacePath, ".devcontainer");
1051
- if (existsSync(devcontainerDir)) {
1052
- const composeFiles = readdirSync(devcontainerDir).filter((f) => f.includes("compose") && (f.endsWith(".yml") || f.endsWith(".yaml")));
1053
- for (const composeFile of composeFiles) sanitizeComposeFileSync(join$1(devcontainerDir, composeFile));
1054
- if (composeFiles.length > 0) result.steps.push(`Sanitized ${composeFiles.length} compose file(s) for platform compatibility`);
1055
- }
1056
- progress("Installing dependencies", projectConfig.package_manager || "detecting...");
1057
- const pkgManager = projectConfig.package_manager || (existsSync(join$1(workspacePath, "bun.lock")) ? "bun" : "npm");
1058
- const staleModulesDirs = [join$1(workspacePath, "node_modules"), ...(projectConfig.workspace_packages ?? []).map((p) => join$1(workspacePath, p.path, "node_modules"))];
1059
- for (const dir of staleModulesDirs) if (existsSync(dir)) await execAsync$1(`rm -rf "${dir}"`);
1060
- const installCmd = pkgManager === "bun" ? "bun install" : `${pkgManager} install`;
1061
- try {
1062
- await execAsync$1(installCmd, {
1063
- cwd: workspacePath,
1064
- encoding: "utf-8"
1065
- });
1066
- result.steps.push(`Installed dependencies (${pkgManager})`);
1067
- progress("Installing dependencies", `${pkgManager} — done`, "complete");
1068
- } catch (installErr) {
1069
- const msg = `Dependency install failed (${pkgManager}): ${installErr.message?.slice(0, 200)}`;
1070
- result.errors.push(msg);
1071
- progress("Installing dependencies", "Failed — workspace creation aborted", "complete");
1072
- return result;
1073
- }
1074
- const hookTargets = workspaceConfig.type === "polyrepo" && workspaceConfig.repos ? workspaceConfig.repos.filter((repo) => repo.link_type !== "symlink").map((repo) => join$1(workspacePath, repo.name)).filter((path) => existsSync(join$1(path, ".git"))) : [workspacePath];
1075
- try {
1076
- for (const hookTarget of hookTargets) await installPreRebaseHook(hookTarget);
1077
- } catch (hookErr) {
1078
- result.errors.push(`Pre-rebase guard install failed: ${hookErr.message?.slice(0, 200)}`);
1079
- return result;
1080
- }
1081
- const workspacePackages = projectConfig.workspace_packages;
1082
- if (workspacePackages && workspacePackages.length > 0) {
1083
- progress("Building workspace packages", workspacePackages.map((p) => p.path).join(", "));
1084
- for (const pkg of workspacePackages) try {
1085
- await execAsync$1(pkg.build_command, {
1086
- cwd: join$1(workspacePath, pkg.path),
1263
+ try {
1264
+ ensurePanGitignoreSync(projectConfig.path);
1265
+ result.steps.push("Verified runtime-only Overdeck and Claude Code sync paths are in .gitignore");
1266
+ } catch (gitignoreErr) {
1267
+ result.steps.push(`Warning: could not update .gitignore: ${gitignoreErr.message}`);
1268
+ }
1269
+ const devcontainerDir = join$1(workspacePath, ".devcontainer");
1270
+ if (existsSync(devcontainerDir)) {
1271
+ const composeFiles = readdirSync(devcontainerDir).filter((f) => f.includes("compose") && (f.endsWith(".yml") || f.endsWith(".yaml")));
1272
+ for (const composeFile of composeFiles) sanitizeComposeFileSync(join$1(devcontainerDir, composeFile));
1273
+ if (composeFiles.length > 0) result.steps.push(`Sanitized ${composeFiles.length} compose file(s) for platform compatibility`);
1274
+ }
1275
+ progress("Installing dependencies", projectConfig.package_manager || "detecting...");
1276
+ const pkgManager = projectConfig.package_manager || (existsSync(join$1(workspacePath, "bun.lock")) ? "bun" : "npm");
1277
+ const staleModulesDirs = [join$1(workspacePath, "node_modules"), ...(projectConfig.workspace_packages ?? []).map((p) => join$1(workspacePath, p.path, "node_modules"))];
1278
+ for (const dir of staleModulesDirs) if (existsSync(dir)) await execAsync$1(`rm -rf "${dir}"`);
1279
+ const installCmd = pkgManager === "bun" ? "bun install" : `${pkgManager} install`;
1280
+ try {
1281
+ await execAsync$1(installCmd, {
1282
+ cwd: workspacePath,
1087
1283
  encoding: "utf-8"
1088
1284
  });
1089
- result.steps.push(`Built workspace package: ${pkg.path}`);
1090
- } catch (buildErr) {
1091
- const msg = `Workspace package build failed (${pkg.path}): ${buildErr.message?.slice(0, 200)}`;
1285
+ result.steps.push(`Installed dependencies (${pkgManager})`);
1286
+ progress("Installing dependencies", `${pkgManager} — done`, "complete");
1287
+ } catch (installErr) {
1288
+ const msg = `Dependency install failed (${pkgManager}): ${installErr.message?.slice(0, 200)}`;
1092
1289
  result.errors.push(msg);
1093
- progress("Building workspace packages", `Failed on ${pkg.path} — workspace creation aborted`, "complete");
1290
+ progress("Installing dependencies", "Failed — workspace creation aborted", "complete");
1094
1291
  return result;
1095
1292
  }
1096
- progress("Building workspace packages", "Packages built", "complete");
1097
- }
1098
- try {
1099
- await execAsync$1("python3 --version");
1100
- const venvPath = join$1(workspacePath, ".venv");
1101
- const tldrBin = join$1(venvPath, "bin", "tldr");
1102
- if (existsSync(join$1(projectConfig.path, ".venv", "bin", "tldr"))) {
1103
- const mainVenvPath = join$1(projectConfig.path, ".venv");
1104
- await execAsync$1(`cp -a "${mainVenvPath}" "${venvPath}"`);
1105
- relocateVenvScripts(mainVenvPath, venvPath);
1106
- result.steps.push("Copied Python venv from main branch (shebangs relocated)");
1107
- } else {
1108
- await execAsync$1(`python3 -m venv "${venvPath}"`, { cwd: workspacePath });
1109
- await execAsync$1(`"${join$1(venvPath, "bin", "pip")}" install llm-tldr`, {
1110
- cwd: workspacePath,
1111
- timeout: 12e4
1112
- });
1113
- result.steps.push("Created Python venv and installed llm-tldr");
1114
- const patchScript = join$1(projectConfig.path, "scripts", "patches", "llm-tldr-tsx-support.py");
1115
- if (existsSync(patchScript)) {
1116
- await execAsync$1(`python3 "${patchScript}" "${venvPath}"`);
1117
- result.steps.push("Applied llm-tldr .tsx/.jsx patch");
1293
+ const hookTargets = workspaceConfig.type === "polyrepo" && workspaceConfig.repos ? workspaceConfig.repos.filter((repo) => repo.link_type !== "symlink").map((repo) => join$1(workspacePath, repo.name)).filter((path) => existsSync(join$1(path, ".git"))) : [workspacePath];
1294
+ try {
1295
+ for (const hookTarget of hookTargets) await installPreRebaseHook(hookTarget);
1296
+ } catch (hookErr) {
1297
+ result.errors.push(`Pre-rebase guard install failed: ${hookErr.message?.slice(0, 200)}`);
1298
+ return result;
1299
+ }
1300
+ const workspacePackages = projectConfig.workspace_packages;
1301
+ if (workspacePackages && workspacePackages.length > 0) {
1302
+ progress("Building workspace packages", workspacePackages.map((p) => p.path).join(", "));
1303
+ for (const pkg of workspacePackages) try {
1304
+ await execAsync$1(pkg.build_command, {
1305
+ cwd: join$1(workspacePath, pkg.path),
1306
+ encoding: "utf-8"
1307
+ });
1308
+ result.steps.push(`Built workspace package: ${pkg.path}`);
1309
+ } catch (buildErr) {
1310
+ const msg = `Workspace package build failed (${pkg.path}): ${buildErr.message?.slice(0, 200)}`;
1311
+ result.errors.push(msg);
1312
+ progress("Building workspace packages", `Failed on ${pkg.path} — workspace creation aborted`, "complete");
1313
+ return result;
1118
1314
  }
1315
+ progress("Building workspace packages", "Packages built", "complete");
1119
1316
  }
1120
- if (!existsSync(tldrBin)) result.steps.push("TLDR setup incomplete: tldr binary not found after venv creation");
1121
- else {
1122
- const mainTldrDir = join$1(projectConfig.path, ".tldr");
1123
- const workspaceTldrDir = join$1(workspacePath, ".tldr");
1124
- if (existsSync(mainTldrDir)) {
1125
- await execAsync$1(`cp -r "${mainTldrDir}" "${workspaceTldrDir}"`);
1126
- result.steps.push("Copied TLDR index from main branch");
1317
+ try {
1318
+ await execAsync$1("python3 --version");
1319
+ const venvPath = join$1(workspacePath, ".venv");
1320
+ const tldrBin = join$1(venvPath, "bin", "tldr");
1321
+ if (existsSync(join$1(projectConfig.path, ".venv", "bin", "tldr"))) {
1322
+ const mainVenvPath = join$1(projectConfig.path, ".venv");
1323
+ await execAsync$1(`cp -a "${mainVenvPath}" "${venvPath}"`);
1324
+ relocateVenvScripts(mainVenvPath, venvPath);
1325
+ result.steps.push("Copied Python venv from main branch (shebangs relocated)");
1326
+ } else {
1327
+ await execAsync$1(`python3 -m venv "${venvPath}"`, { cwd: workspacePath });
1328
+ await execAsync$1(`"${join$1(venvPath, "bin", "pip")}" install llm-tldr`, {
1329
+ cwd: workspacePath,
1330
+ timeout: 12e4
1331
+ });
1332
+ result.steps.push("Created Python venv and installed llm-tldr");
1333
+ const patchScript = join$1(projectConfig.path, "scripts", "patches", "llm-tldr-tsx-support.py");
1334
+ if (existsSync(patchScript)) {
1335
+ await execAsync$1(`python3 "${patchScript}" "${venvPath}"`);
1336
+ result.steps.push("Applied llm-tldr .tsx/.jsx patch");
1337
+ }
1338
+ }
1339
+ if (!existsSync(tldrBin)) result.steps.push("TLDR setup incomplete: tldr binary not found after venv creation");
1340
+ else {
1341
+ const mainTldrDir = join$1(projectConfig.path, ".tldr");
1342
+ const workspaceTldrDir = join$1(workspacePath, ".tldr");
1343
+ if (existsSync(mainTldrDir)) {
1344
+ await execAsync$1(`cp -r "${mainTldrDir}" "${workspaceTldrDir}"`);
1345
+ result.steps.push("Copied TLDR index from main branch");
1346
+ }
1347
+ const { getTldrDaemonServiceSync } = await import("./tldr-daemon-B1Jhrtc8.js");
1348
+ const tldrService = getTldrDaemonServiceSync(workspacePath, venvPath);
1349
+ await tldrService.start(true);
1350
+ result.steps.push("Started TLDR daemon");
1351
+ try {
1352
+ await tldrService.warm(true);
1353
+ result.steps.push("TLDR index warm initiated (background)");
1354
+ } catch {}
1355
+ }
1356
+ } catch (error) {
1357
+ if (error.message?.includes("python3")) result.steps.push("Skipped TLDR setup (python3 not available)");
1358
+ else {
1359
+ console.warn(`⚠ TLDR setup failed: ${error.message}`);
1360
+ result.steps.push(`TLDR setup failed: ${error.message}`);
1127
1361
  }
1128
- const { getTldrDaemonServiceSync } = await import("./tldr-daemon-CvWXBhX1.js");
1129
- const tldrService = getTldrDaemonServiceSync(workspacePath, venvPath);
1130
- await tldrService.start(true);
1131
- result.steps.push("Started TLDR daemon");
1132
- try {
1133
- await tldrService.warm(true);
1134
- result.steps.push("TLDR index warm initiated (background)");
1135
- } catch {}
1136
1362
  }
1137
- } catch (error) {
1138
- if (error.message?.includes("python3")) result.steps.push("Skipped TLDR setup (python3 not available)");
1139
- else {
1140
- console.warn(`⚠ TLDR setup failed: ${error.message}`);
1141
- result.steps.push(`TLDR setup failed: ${error.message}`);
1363
+ if (workspaceConfig.dns) {
1364
+ const dnsMethod = workspaceConfig.dns.sync_method || "wsl2hosts";
1365
+ for (const entryPattern of workspaceConfig.dns.entries) {
1366
+ const hostname = replacePlaceholdersSync(entryPattern, placeholders);
1367
+ if (addDnsEntry(dnsMethod, hostname)) result.steps.push(`Added DNS entry: ${hostname} (${dnsMethod})`);
1368
+ }
1369
+ if (dnsMethod === "wsl2hosts") {
1370
+ if (await syncDnsToWindows()) result.steps.push("Synced DNS to Windows hosts file");
1371
+ }
1142
1372
  }
1143
- }
1144
- if (workspaceConfig.dns) {
1145
- const dnsMethod = workspaceConfig.dns.sync_method || "wsl2hosts";
1146
- for (const entryPattern of workspaceConfig.dns.entries) {
1147
- const hostname = replacePlaceholdersSync(entryPattern, placeholders);
1148
- if (addDnsEntry(dnsMethod, hostname)) result.steps.push(`Added DNS entry: ${hostname} (${dnsMethod})`);
1373
+ if (workspaceConfig.ports) for (const [portName, portConfig] of Object.entries(workspaceConfig.ports)) {
1374
+ const portFile = join$1(projectConfig.path, `.${portName}-ports`);
1375
+ try {
1376
+ const port = assignPort(portFile, featureFolder, portConfig.range);
1377
+ result.steps.push(`Assigned ${portName} port: ${port}`);
1378
+ placeholders[`${portName.toUpperCase()}_PORT`] = String(port);
1379
+ } catch (error) {
1380
+ result.errors.push(`Failed to assign ${portName} port: ${error}`);
1381
+ }
1149
1382
  }
1150
- if (dnsMethod === "wsl2hosts") {
1151
- if (await syncDnsToWindows()) result.steps.push("Synced DNS to Windows hosts file");
1383
+ progress("Installing skills & templates", "Overdeck skills, agents, rules");
1384
+ const mergeResult = mergeSkillsIntoWorkspaceSync(workspacePath);
1385
+ const mergeTotal = mergeResult.added.length + mergeResult.updated.length;
1386
+ if (mergeTotal > 0) result.steps.push(`Installed ${mergeTotal} Overdeck files (${mergeResult.added.length} new, ${mergeResult.updated.length} updated)`);
1387
+ const panMergeResult = mergePanSkillsIntoWorkspaceSync(projectConfig.path, workspacePath);
1388
+ if (panMergeResult.added.length > 0) result.steps.push(`Installed ${panMergeResult.added.length} project-local skill file(s) from .pan/skills/ (${panMergeResult.overlayed.join(", ")})`);
1389
+ if (workspaceConfig.agent?.template_dir) {
1390
+ const templateDir = join$1(projectConfig.path, workspaceConfig.agent.template_dir);
1391
+ const templateSteps = processTemplatesSync(templateDir, workspacePath, placeholders, workspaceConfig.agent.templates);
1392
+ result.steps.push(...templateSteps);
1393
+ const dirsToSync = workspaceConfig.agent.copy_dirs || workspaceConfig.agent.symlinks;
1394
+ if (dirsToSync) {
1395
+ const copySteps = copyProjectTemplateDirs(templateDir, workspacePath, dirsToSync, placeholders);
1396
+ result.steps.push(...copySteps);
1397
+ }
1152
1398
  }
1153
- }
1154
- if (workspaceConfig.ports) for (const [portName, portConfig] of Object.entries(workspaceConfig.ports)) {
1155
- const portFile = join$1(projectConfig.path, `.${portName}-ports`);
1156
- try {
1157
- const port = assignPort(portFile, featureFolder, portConfig.range);
1158
- result.steps.push(`Assigned ${portName} port: ${port}`);
1159
- placeholders[`${portName.toUpperCase()}_PORT`] = String(port);
1160
- } catch (error) {
1161
- result.errors.push(`Failed to assign ${portName} port: ${error}`);
1399
+ if (workspaceConfig.env?.template) {
1400
+ const envContent = replacePlaceholdersSync(workspaceConfig.env.template, placeholders);
1401
+ writeFileSync(join$1(workspacePath, ".env"), envContent);
1402
+ result.steps.push("Created .env file");
1162
1403
  }
1163
- }
1164
- progress("Installing skills & templates", "Overdeck skills, agents, rules");
1165
- const mergeResult = mergeSkillsIntoWorkspaceSync(workspacePath);
1166
- const mergeTotal = mergeResult.added.length + mergeResult.updated.length;
1167
- if (mergeTotal > 0) result.steps.push(`Installed ${mergeTotal} Overdeck files (${mergeResult.added.length} new, ${mergeResult.updated.length} updated)`);
1168
- const panMergeResult = mergePanSkillsIntoWorkspaceSync(projectConfig.path, workspacePath);
1169
- if (panMergeResult.added.length > 0) result.steps.push(`Installed ${panMergeResult.added.length} project-local skill file(s) from .pan/skills/ (${panMergeResult.overlayed.join(", ")})`);
1170
- if (workspaceConfig.agent?.template_dir) {
1171
- const templateDir = join$1(projectConfig.path, workspaceConfig.agent.template_dir);
1172
- const templateSteps = processTemplatesSync(templateDir, workspacePath, placeholders, workspaceConfig.agent.templates);
1173
- result.steps.push(...templateSteps);
1174
- const dirsToSync = workspaceConfig.agent.copy_dirs || workspaceConfig.agent.symlinks;
1175
- if (dirsToSync) {
1176
- const copySteps = copyProjectTemplateDirs(templateDir, workspacePath, dirsToSync, placeholders);
1177
- result.steps.push(...copySteps);
1404
+ if (workspaceConfig.docker?.compose_template) try {
1405
+ const renderResult = renderDevcontainerSync({
1406
+ workspacePath,
1407
+ projectConfig,
1408
+ featureName
1409
+ });
1410
+ result.steps.push(...renderResult.steps);
1411
+ for (const warning of renderResult.warnings) result.errors.push(warning);
1412
+ } catch (err) {
1413
+ result.errors.push(`Failed to render .devcontainer/: ${err.message ?? err}`);
1178
1414
  }
1179
- }
1180
- if (workspaceConfig.env?.template) {
1181
- const envContent = replacePlaceholdersSync(workspaceConfig.env.template, placeholders);
1182
- writeFileSync(join$1(workspacePath, ".env"), envContent);
1183
- result.steps.push("Created .env file");
1184
- }
1185
- if (workspaceConfig.docker?.compose_template) try {
1186
- const renderResult = renderDevcontainerSync({
1187
- workspacePath,
1188
- projectConfig,
1189
- featureName
1190
- });
1191
- result.steps.push(...renderResult.steps);
1192
- for (const warning of renderResult.warnings) result.errors.push(warning);
1193
- } catch (err) {
1194
- result.errors.push(`Failed to render .devcontainer/: ${err.message ?? err}`);
1195
- }
1196
- if (workspaceConfig.tunnel) {
1197
- const tunnelResult = await Effect.runPromise(addTunnelIngress(workspaceConfig.tunnel, placeholders));
1198
- result.steps.push(...tunnelResult.steps);
1199
- if (!tunnelResult.success) result.errors.push("Tunnel setup had failures (see steps for details)");
1200
- }
1201
- if (workspaceConfig.hume) {
1202
- const humeResult = await Effect.runPromise(createHumeConfig(workspaceConfig.hume, placeholders));
1203
- result.steps.push(...humeResult.steps);
1204
- if (humeResult.configId) {
1205
- writeFileSync(join$1(workspacePath, ".hume-config"), `HUME_CONFIG_ID=${humeResult.configId}\nVITE_HUME_CONFIG_ID=${humeResult.configId}\n`);
1206
- result.steps.push("Wrote .hume-config with Hume EVI config ID");
1415
+ if (workspaceConfig.tunnel) {
1416
+ const tunnelResult = await Effect.runPromise(addTunnelIngress(workspaceConfig.tunnel, placeholders));
1417
+ result.steps.push(...tunnelResult.steps);
1418
+ if (!tunnelResult.success) result.errors.push("Tunnel setup had failures (see steps for details)");
1207
1419
  }
1208
- if (!humeResult.success) result.errors.push("Hume EVI config setup had failures (see steps for details)");
1209
- }
1210
- progress("Installing skills & templates", "Skills and templates ready", "complete");
1211
- if (startDocker) {
1212
- progress("Starting Docker containers", "Building and starting services");
1213
- if (workspaceConfig.docker?.traefik) {
1214
- const traefikPath = join$1(homedir(), ".overdeck", "traefik", "docker-compose.yml");
1215
- if (existsSync(traefikPath)) try {
1216
- await execAsync$1(`docker compose -f "${traefikPath}" up -d`, { cwd: join$1(homedir(), ".overdeck", "traefik") });
1217
- result.steps.push("Started Traefik");
1218
- } catch (error) {
1219
- const msg = error?.message || String(error);
1220
- if (msg.includes("port is already allocated") || msg.includes("address already in use")) result.steps.push("Traefik already running (port in use)");
1221
- else result.errors.push(`Failed to start Traefik: ${error}`);
1420
+ if (workspaceConfig.hume) {
1421
+ const humeResult = await Effect.runPromise(createHumeConfig(workspaceConfig.hume, placeholders));
1422
+ result.steps.push(...humeResult.steps);
1423
+ if (humeResult.configId) {
1424
+ writeFileSync(join$1(workspacePath, ".hume-config"), `HUME_CONFIG_ID=${humeResult.configId}\nVITE_HUME_CONFIG_ID=${humeResult.configId}\n`);
1425
+ result.steps.push("Wrote .hume-config with Hume EVI config ID");
1222
1426
  }
1427
+ if (!humeResult.success) result.errors.push("Hume EVI config setup had failures (see steps for details)");
1223
1428
  }
1224
- const composeLocations = [
1225
- join$1(workspacePath, "docker-compose.yml"),
1226
- join$1(workspacePath, "docker-compose.yaml"),
1227
- join$1(workspacePath, ".devcontainer", "docker-compose.yml"),
1228
- join$1(workspacePath, ".devcontainer", "docker-compose.devcontainer.yml")
1229
- ];
1230
- for (const composePath of composeLocations) if (existsSync(composePath)) {
1231
- try {
1232
- await execAsync$1(`docker compose -f "${composePath}" up -d --build`, {
1233
- cwd: dirname$1(composePath),
1234
- timeout: 3e5
1235
- });
1236
- result.steps.push(`Started containers from ${basename$1(composePath)}`);
1237
- } catch (error) {
1238
- result.errors.push(`Failed to start containers: ${error}`);
1429
+ progress("Installing skills & templates", "Skills and templates ready", "complete");
1430
+ if (startDocker) {
1431
+ progress("Starting Docker containers", "Building and starting services");
1432
+ if (workspaceConfig.docker?.traefik) {
1433
+ const traefikPath = join$1(homedir(), ".overdeck", "traefik", "docker-compose.yml");
1434
+ if (existsSync(traefikPath)) try {
1435
+ await execAsync$1(`docker compose -f "${traefikPath}" up -d`, { cwd: join$1(homedir(), ".overdeck", "traefik") });
1436
+ result.steps.push("Started Traefik");
1437
+ } catch (error) {
1438
+ const msg = error?.message || String(error);
1439
+ if (msg.includes("port is already allocated") || msg.includes("address already in use")) result.steps.push("Traefik already running (port in use)");
1440
+ else result.errors.push(`Failed to start Traefik: ${error}`);
1441
+ }
1442
+ }
1443
+ const composeLocations = [
1444
+ join$1(workspacePath, "docker-compose.yml"),
1445
+ join$1(workspacePath, "docker-compose.yaml"),
1446
+ join$1(workspacePath, ".devcontainer", "docker-compose.yml"),
1447
+ join$1(workspacePath, ".devcontainer", "docker-compose.devcontainer.yml")
1448
+ ];
1449
+ for (const composePath of composeLocations) if (existsSync(composePath)) {
1450
+ try {
1451
+ await execAsync$1(`docker compose -f "${composePath}" up -d --build`, {
1452
+ cwd: dirname$1(composePath),
1453
+ timeout: 3e5
1454
+ });
1455
+ result.steps.push(`Started containers from ${basename$1(composePath)}`);
1456
+ } catch (error) {
1457
+ result.errors.push(`Failed to start containers: ${error}`);
1458
+ }
1459
+ break;
1239
1460
  }
1240
- break;
1241
1461
  }
1462
+ if (startDocker) progress("Starting Docker containers", "Containers running", "complete");
1463
+ try {
1464
+ preTrustDirectorySync(workspacePath);
1465
+ result.steps.push("Pre-trusted workspace in Claude Code");
1466
+ } catch {}
1467
+ try {
1468
+ const { determineCavemanVariant, injectCavemanSettings } = await import("./workspace-Cn9ywfSW.js");
1469
+ const cavemanConfig = loadConfigSync().config.caveman;
1470
+ const variant = determineCavemanVariant(cavemanConfig);
1471
+ await Effect.runPromise(injectCavemanSettings(workspacePath, variant));
1472
+ if (variant === "enabled") result.steps.push("Injected caveman compression hooks into .claude/settings.json");
1473
+ else if (variant === "disabled") result.steps.push("Caveman A/B test: assigned disabled variant for this workspace");
1474
+ } catch (cavemanErr) {
1475
+ result.steps.push(`Caveman setup skipped: ${cavemanErr instanceof Error ? cavemanErr.message : String(cavemanErr)}`);
1476
+ }
1477
+ try {
1478
+ const settingsResult = copyOverdeckSettingsToWorkspaceSync(workspacePath);
1479
+ if (settingsResult.copied.length > 0) result.steps.push(`Copied Overdeck settings into workspace (${settingsResult.copied.length} file(s))`);
1480
+ } catch (settingsErr) {
1481
+ result.steps.push(`Overdeck settings copy skipped: ${settingsErr instanceof Error ? settingsErr.message : String(settingsErr)}`);
1482
+ }
1483
+ try {
1484
+ const { injectMemoryHookSettings } = await import("./workspace-Cn9ywfSW.js");
1485
+ await injectMemoryHookSettings(workspacePath);
1486
+ result.steps.push("Injected memory hooks into .claude/settings.json");
1487
+ } catch (memoryHookErr) {
1488
+ result.steps.push(`Memory hook setup skipped: ${memoryHookErr instanceof Error ? memoryHookErr.message : String(memoryHookErr)}`);
1489
+ }
1490
+ result.success = result.errors.length === 0;
1491
+ return result;
1492
+ })();
1493
+ if (!outcome.success && createdWorkspaceRowId && !worktreeCreated) try {
1494
+ await deleteWorkspace(createdWorkspaceRowId);
1495
+ } catch (err) {
1496
+ outcome.errors.push(`Also failed to compensate the pre-created workspace row: ${err instanceof Error ? err.message : String(err)}`);
1242
1497
  }
1243
- if (startDocker) progress("Starting Docker containers", "Containers running", "complete");
1244
- try {
1245
- preTrustDirectorySync(workspacePath);
1246
- result.steps.push("Pre-trusted workspace in Claude Code");
1247
- } catch {}
1248
- try {
1249
- const { determineCavemanVariant, injectCavemanSettings } = await import("./workspace-COWvdibH.js");
1250
- const cavemanConfig = loadConfigSync().config.caveman;
1251
- const variant = determineCavemanVariant(cavemanConfig);
1252
- await Effect.runPromise(injectCavemanSettings(workspacePath, variant));
1253
- if (variant === "enabled") result.steps.push("Injected caveman compression hooks into .claude/settings.json");
1254
- else if (variant === "disabled") result.steps.push("Caveman A/B test: assigned disabled variant for this workspace");
1255
- } catch (cavemanErr) {
1256
- result.steps.push(`Caveman setup skipped: ${cavemanErr instanceof Error ? cavemanErr.message : String(cavemanErr)}`);
1257
- }
1258
- try {
1259
- const settingsResult = copyOverdeckSettingsToWorkspaceSync(workspacePath);
1260
- if (settingsResult.copied.length > 0) result.steps.push(`Copied Overdeck settings into workspace (${settingsResult.copied.length} file(s))`);
1261
- } catch (settingsErr) {
1262
- result.steps.push(`Overdeck settings copy skipped: ${settingsErr instanceof Error ? settingsErr.message : String(settingsErr)}`);
1263
- }
1264
- try {
1265
- const { injectMemoryHookSettings } = await import("./workspace-COWvdibH.js");
1266
- await injectMemoryHookSettings(workspacePath);
1267
- result.steps.push("Injected memory hooks into .claude/settings.json");
1268
- } catch (memoryHookErr) {
1269
- result.steps.push(`Memory hook setup skipped: ${memoryHookErr instanceof Error ? memoryHookErr.message : String(memoryHookErr)}`);
1270
- }
1271
- result.success = result.errors.length === 0;
1272
- return result;
1498
+ return outcome;
1273
1499
  }
1274
1500
  var execAsync$1;
1275
1501
  var init_create = __esmMin((() => {
@@ -1282,6 +1508,9 @@ var init_create = __esmMin((() => {
1282
1508
  init_pan_dir();
1283
1509
  init_migration();
1284
1510
  init_worktree_ops();
1511
+ init_resolver();
1512
+ init_writer();
1513
+ init_projects();
1285
1514
  init_devcontainer_renderer();
1286
1515
  execAsync$1 = promisify(exec);
1287
1516
  }));
@@ -1347,7 +1576,7 @@ async function removeWorkspacePromise(options) {
1347
1576
  }
1348
1577
  const venvPath = join$1(workspacePath, ".venv");
1349
1578
  if (existsSync(venvPath)) try {
1350
- const { getTldrDaemonServiceSync } = await import("./tldr-daemon-CvWXBhX1.js");
1579
+ const { getTldrDaemonServiceSync } = await import("./tldr-daemon-B1Jhrtc8.js");
1351
1580
  await getTldrDaemonServiceSync(workspacePath, venvPath).stop();
1352
1581
  result.steps.push("Stopped TLDR daemon");
1353
1582
  } catch (error) {
@@ -1467,6 +1696,6 @@ var init_workspace_manager = __esmMin((() => {
1467
1696
  });
1468
1697
  }));
1469
1698
  //#endregion
1470
- export { removeWorkspace as a, installGitHooksInDir as c, relocateVenvScripts as d, detectPlatform as f, ensurePanGitignoreSync as h, preTrustDirectory as i, installPreRebaseHook as l, copyOverdeckSettingsToWorkspaceSync as m, getContainersReferencingWorkspacePath as n, stopWorkspaceDocker as o, init_platform as p, init_workspace_manager as r, init_git_hooks as s, createWorkspace as t, preTrustDirectorySync as u };
1699
+ export { detectPlatform as C, ensurePanGitignoreSync as E, relocateVenvScripts as S, copyOverdeckSettingsToWorkspaceSync as T, init_identity_record as _, removeWorkspace as a, installPreRebaseHook as b, installGitHooksInDir as c, init_writer as d, setWorkspaceFavorite as f, upsertProjectFromConfig as g, updateWorkspaceLayout as h, preTrustDirectory as i, archiveWorkspace as l, unarchiveWorkspace as m, getContainersReferencingWorkspacePath as n, stopWorkspaceDocker as o, touchWorkspaceAccessed as p, init_workspace_manager as r, init_git_hooks as s, createWorkspace as t, createWorkspace$1 as u, readWorkspaceIdentity as v, init_platform as w, preTrustDirectorySync as x, writeWorkspaceIdentity as y };
1471
1700
 
1472
- //# sourceMappingURL=workspace-manager-BPgTrG66.js.map
1701
+ //# sourceMappingURL=workspace-manager-Bem7ZBs9.js.map