@outerlayer/cli 0.34.0-next.20261028183303 → 0.34.0-next.20261029100612

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 (189) hide show
  1. package/README.md +7 -0
  2. package/dist/agent-setup-UPIHHKI2.js +32 -0
  3. package/dist/{artifact-link-cmd-CSVFEM5O.js → artifact-link-cmd-6LFCTDBD.js} +5 -5
  4. package/dist/{bridge-4GRZFXJU.js → bridge-XM4QLKIX.js} +2 -2
  5. package/dist/{build-SEJJWGTO.js → build-UBZNVGY2.js} +10 -10
  6. package/dist/{build-disk-EYRR3PBT.js → build-disk-Y3MMWFYE.js} +7 -7
  7. package/dist/build-info.json +1 -1
  8. package/dist/{builder-T7B46P7T.js → builder-SX4W5VF3.js} +6 -6
  9. package/dist/caller-IIA2TPAA.js +18 -0
  10. package/dist/{check-VKSOYRNI.js → check-PVB3GPFQ.js} +88 -70
  11. package/dist/{chunk-ANPNT6PM.js → chunk-2AM6Z5BP.js} +1 -1
  12. package/dist/{chunk-3UIXIGYT.js → chunk-2B6EKUBD.js} +4 -4
  13. package/dist/{chunk-QGDGGLSD.js → chunk-2F43WNKI.js} +3 -3
  14. package/dist/{chunk-UZEIBWTP.js → chunk-2OE4BZRF.js} +8 -8
  15. package/dist/{chunk-VNVZDWO3.js → chunk-352DHUTP.js} +4 -1
  16. package/dist/{chunk-W7E6IMEW.js → chunk-3EEJGQEJ.js} +22 -21
  17. package/dist/{chunk-5W2YSWIW.js → chunk-4PH4DVV4.js} +1 -1
  18. package/dist/{chunk-WH3FPBPO.js → chunk-4PWOZU7R.js} +82 -33
  19. package/dist/{chunk-ZJSNLVCE.js → chunk-545P7JY7.js} +1 -1
  20. package/dist/{chunk-RRXS4CWE.js → chunk-5C7QZBLI.js} +9 -7
  21. package/dist/{chunk-2EEW6FJN.js → chunk-5FWBAM6O.js} +1 -1
  22. package/dist/{chunk-T2Q7ISPE.js → chunk-5WYT3PPE.js} +1 -1
  23. package/dist/{chunk-ARL6X6Y4.js → chunk-62TMOXQN.js} +2 -2
  24. package/dist/{chunk-EA2PQRCU.js → chunk-7CIU64OH.js} +6 -6
  25. package/dist/{chunk-AF4E4I4T.js → chunk-7G35LX5D.js} +11 -11
  26. package/dist/{chunk-KH4774QT.js → chunk-7R655ODT.js} +1 -1
  27. package/dist/{chunk-G2JWZDFA.js → chunk-A2LHHKTT.js} +3 -3
  28. package/dist/{chunk-ESVW4MJY.js → chunk-AAGU5FJF.js} +1 -1
  29. package/dist/{chunk-QGEGLZSY.js → chunk-ADI2CCDX.js} +47 -7
  30. package/dist/{chunk-I2MFIT6X.js → chunk-AGMR4IQE.js} +29 -28
  31. package/dist/{chunk-SAAVZ2BX.js → chunk-AUVJMR3P.js} +1 -1
  32. package/dist/{chunk-HFOZTCTN.js → chunk-AVHPSB65.js} +7 -7
  33. package/dist/{chunk-KQDK4Q6A.js → chunk-CDVG2LXT.js} +10 -10
  34. package/dist/{chunk-TUSYOL2O.js → chunk-CJPTUU2E.js} +1 -1
  35. package/dist/{chunk-OYQVLQP3.js → chunk-EQ5Y2OMK.js} +16 -14
  36. package/dist/{chunk-MH6QLXUO.js → chunk-FJ7KTNMD.js} +1 -1
  37. package/dist/{chunk-KPEMNHVF.js → chunk-FNKCMOQY.js} +3 -3
  38. package/dist/{chunk-2O5KA67H.js → chunk-FUJUFLDC.js} +2 -2
  39. package/dist/{chunk-CRB3POP4.js → chunk-FZKNTIOJ.js} +1 -1
  40. package/dist/{chunk-YLPJOUVF.js → chunk-GANAOCHR.js} +6 -1
  41. package/dist/{chunk-3KGXXTMN.js → chunk-GBMTKV5B.js} +5 -5
  42. package/dist/{chunk-POND2SMT.js → chunk-H2GESWLW.js} +3 -3
  43. package/dist/{chunk-DCBFUUDL.js → chunk-HERRKKES.js} +7 -7
  44. package/dist/{chunk-V2S2WRGD.js → chunk-HS5QEIJT.js} +11 -11
  45. package/dist/{chunk-PJDQPF5N.js → chunk-HWVMRETT.js} +1 -1
  46. package/dist/{chunk-H7MGR2GN.js → chunk-IUPYSGCP.js} +6 -6
  47. package/dist/{chunk-7JSWRF5O.js → chunk-JFALOM5G.js} +10 -10
  48. package/dist/{chunk-XDAMLX2L.js → chunk-JQOET7TF.js} +9 -9
  49. package/dist/{chunk-RQ3GCCHH.js → chunk-JXXMOAJG.js} +2 -2
  50. package/dist/{chunk-URIZRCRY.js → chunk-KYDEBGJG.js} +1 -1
  51. package/dist/{chunk-GG5OE6MY.js → chunk-KZUHEN26.js} +2 -2
  52. package/dist/{chunk-2EHDLYSL.js → chunk-LFXLFDEA.js} +30 -22
  53. package/dist/chunk-LW2A24IA.js +31 -0
  54. package/dist/{chunk-BBJ6BM5U.js → chunk-MKSZHT6S.js} +1 -1
  55. package/dist/{chunk-VX7WZK7J.js → chunk-MOG4XCYS.js} +189 -121
  56. package/dist/{chunk-P2PNBDUT.js → chunk-NM3L4JBB.js} +4 -4
  57. package/dist/{chunk-TDCHUEKY.js → chunk-O7CGRDRQ.js} +5 -5
  58. package/dist/{chunk-KT4CN6OU.js → chunk-OHQMGLJP.js} +3 -3
  59. package/dist/{chunk-5BHIBJDA.js → chunk-OLM2TIOW.js} +1 -1
  60. package/dist/{chunk-VEVNGDTP.js → chunk-PDK35AR4.js} +2 -2
  61. package/dist/{chunk-RPST2GNG.js → chunk-PQ5YDDDE.js} +3 -3
  62. package/dist/{chunk-OKJXZXYH.js → chunk-PUSCE544.js} +6 -6
  63. package/dist/{chunk-ZEFNJCN3.js → chunk-QM3HMXMU.js} +2 -2
  64. package/dist/chunk-RW3YMQVQ.js +39 -0
  65. package/dist/{chunk-ZCZY3Q55.js → chunk-SHPCVBT3.js} +1 -1
  66. package/dist/{chunk-UXC3RQLF.js → chunk-SQGD4LYW.js} +1 -1
  67. package/dist/{chunk-LJEZGHCH.js → chunk-SYCZTZXD.js} +647 -211
  68. package/dist/{chunk-4YD7N6V3.js → chunk-TKTVKEES.js} +4 -4
  69. package/dist/{chunk-GH2HEEOH.js → chunk-TV2OQUWE.js} +1 -1
  70. package/dist/{chunk-MRLJK4GZ.js → chunk-UGPJIKN4.js} +6 -6
  71. package/dist/{chunk-HH3BQG65.js → chunk-UPRZREBO.js} +1 -1
  72. package/dist/{chunk-ROQPDCRU.js → chunk-UZGQT6OF.js} +1 -1
  73. package/dist/{chunk-NCOL5RYI.js → chunk-VNHBDHX7.js} +1 -1
  74. package/dist/{chunk-64O2NUVA.js → chunk-VO46IHB4.js} +8 -7
  75. package/dist/{chunk-MCPCOKHN.js → chunk-W74HQLLZ.js} +9 -9
  76. package/dist/{chunk-ZCA34T7R.js → chunk-WDDVPDLQ.js} +8 -8
  77. package/dist/{chunk-YF7W7B7Y.js → chunk-WDIZT56W.js} +38 -11
  78. package/dist/{chunk-CUAB7FAZ.js → chunk-WG3VIMD2.js} +8 -8
  79. package/dist/{chunk-IAVT7R6O.js → chunk-WJTIU2A5.js} +6 -6
  80. package/dist/{chunk-NXUZFHMX.js → chunk-WK4OTIAN.js} +3 -3
  81. package/dist/{chunk-T3XPLCJG.js → chunk-XBECMHJW.js} +1 -1
  82. package/dist/{chunk-54LIUIZL.js → chunk-XGSJNXH2.js} +4 -4
  83. package/dist/{chunk-5TXQFZHY.js → chunk-XU5BNWX7.js} +1 -1
  84. package/dist/{chunk-I7RZHMXW.js → chunk-YBAVN6WS.js} +3 -3
  85. package/dist/{chunk-ZTOJIRJH.js → chunk-YBP22LDO.js} +8 -8
  86. package/dist/{chunk-S6UM3N4R.js → chunk-YQHUCOUL.js} +37 -12
  87. package/dist/{chunk-IXRUVR25.js → chunk-YTTESG7K.js} +46 -7
  88. package/dist/{chunk-CKDSPW35.js → chunk-ZI2E4YMY.js} +6 -6
  89. package/dist/{chunk-MEIDQLXQ.js → chunk-ZI7JENTB.js} +1 -1
  90. package/dist/{claude-launcher-7IC6QWR5.js → claude-launcher-MMCKOBND.js} +6 -6
  91. package/dist/{cli-HBS2PXSS.js → cli-W4B35KDN.js} +165 -155
  92. package/dist/{cli-update-notice-4DLZ3655.js → cli-update-notice-T3CXRWNB.js} +3 -3
  93. package/dist/{command-XA6DOFL4.js → command-SKJHW4C4.js} +43 -42
  94. package/dist/{config-RSOCVUKC.js → config-ZDENMTEW.js} +9 -9
  95. package/dist/connect-cmd-APZN6F6N.js +27 -0
  96. package/dist/{container-start-PYW7W2N2.js → container-start-PAUJUXJX.js} +57 -56
  97. package/dist/{context-cleanup-CEZSKNVL.js → context-cleanup-PASDUBGW.js} +5 -5
  98. package/dist/{context-show-cmd-XWLTP6R4.js → context-show-cmd-OWREGUJL.js} +19 -19
  99. package/dist/{control-plane-launch-3MBWPYWZ.js → control-plane-launch-FV5Q6GVJ.js} +16 -16
  100. package/dist/{demo-record-cmd-SIKNTSGI.js → demo-record-cmd-KXLLIMOP.js} +5 -5
  101. package/dist/{demo-voice-cmd-SAB3QU4F.js → demo-voice-cmd-TY2OX2CZ.js} +30 -30
  102. package/dist/{dist-VPXROEZO.js → dist-Z6WP743R.js} +2 -2
  103. package/dist/{docker-YMRPMDOW.js → docker-SKD6VTBD.js} +6 -6
  104. package/dist/{doctor-NVHAE4LS.js → doctor-DX6N3L5T.js} +53 -42
  105. package/dist/emit-artifact-cmd-NFAASCXW.js +43 -0
  106. package/dist/emit-cmd-UOPHEUW5.js +16 -0
  107. package/dist/emit-criteria-cmd-TX4LKO5X.js +33 -0
  108. package/dist/emit-demo-cmd-FRJFQKED.js +47 -0
  109. package/dist/emit-finding-cmd-LO2AKL4P.js +34 -0
  110. package/dist/{emit-result-cmd-VCKNZ4RZ.js → emit-result-cmd-7PL4HNXL.js} +28 -28
  111. package/dist/emit-step-cmd-RZT6VK5U.js +33 -0
  112. package/dist/{exec-client-U4544U2S.js → exec-client-UHL7WPDO.js} +3 -3
  113. package/dist/find-unit-IBL736HQ.js +19 -0
  114. package/dist/{findings-cmd-PLHBAQW4.js → findings-cmd-MEU7GDRC.js} +23 -23
  115. package/dist/fleet-readiness-4RNICYSP.js +28 -0
  116. package/dist/governing-source-6DH2NLPE.js +38 -0
  117. package/dist/{guest-init-MI4SEME4.js → guest-init-2TTQKFFZ.js} +4 -4
  118. package/dist/{hook-fast-GOH4T6SN.js → hook-fast-5PNO5HRO.js} +6 -6
  119. package/dist/{hook-wrap-fast-7VYYAAH4.js → hook-wrap-fast-545QJSBJ.js} +3 -3
  120. package/dist/host-checks-FWPDGTWF.js +78 -0
  121. package/dist/{host-key-OMLDWLNG.js → host-key-Q5DEAP3Q.js} +3 -3
  122. package/dist/{image-tag-YJJONB64.js → image-tag-JWATDMIZ.js} +3 -3
  123. package/dist/index.js +6 -6
  124. package/dist/init-DWOODP2Q.js +57 -0
  125. package/dist/{init-W3ATJYLX.js → init-GF43ZLZI.js} +39 -38
  126. package/dist/{init-cmd-XJOEU2PB.js → init-cmd-LW4TECQH.js} +33 -33
  127. package/dist/{init-update-KX3FFQ5H.js → init-update-5PTU5IE6.js} +30 -30
  128. package/dist/{install-cmd-QTIIMO6B.js → install-cmd-ZEFBJH24.js} +5 -5
  129. package/dist/{layout-7UOBWNYO.js → layout-ZE6F2Z7W.js} +4 -4
  130. package/dist/login-browser-YB7AMKHR.js +13 -0
  131. package/dist/{logout-cmd-5WE2N5B5.js → logout-cmd-Z2PYV5LF.js} +5 -5
  132. package/dist/{logs-YVXVAYTD.js → logs-3YRC7HRA.js} +23 -3
  133. package/dist/loop-UBAR3KBZ.js +89 -0
  134. package/dist/machine-H4Y5X424.js +57 -0
  135. package/dist/{machine-skills-KYN7XJEJ.js → machine-skills-DMHU7OLO.js} +5 -5
  136. package/dist/{mcp-install-cmd-LD7KYAOP.js → mcp-install-cmd-23ZY4IBK.js} +5 -5
  137. package/dist/{mcp-serve-cmd-ECTAPDB3.js → mcp-serve-cmd-PKXIHUOX.js} +9 -9
  138. package/dist/{paths-M66LPPUF.js → paths-7PC3K7C3.js} +2 -2
  139. package/dist/{pending-7LC6XDRO.js → pending-2VIIFAP4.js} +3 -3
  140. package/dist/{pidfile-DSQOOAZV.js → pidfile-KQ2EJABZ.js} +3 -3
  141. package/dist/{record-3KKIJ3XL.js → record-IHEF6C33.js} +3 -3
  142. package/dist/{runner-env-EX7YUIUH.js → runner-env-KCZBSWOB.js} +11 -11
  143. package/dist/{runner-identity-LJWBXNM5.js → runner-identity-D5HQ22D3.js} +6 -6
  144. package/dist/{runner-key-CAUO4RKG.js → runner-key-N5YEMI3S.js} +38 -37
  145. package/dist/session-sender-GJEVFQVN.js +43 -0
  146. package/dist/{settings-3DBYKYQD.js → settings-XB2HYBKO.js} +2 -2
  147. package/dist/{spec-cmd-SAWQYHKM.js → spec-cmd-BRTO5J2C.js} +23 -23
  148. package/dist/{starter-pack-KB3YH4KX.js → starter-pack-WUNNS6G7.js} +9 -9
  149. package/dist/state-FJPSFOID.js +9 -0
  150. package/dist/{status-VMFS7N6A.js → status-UPEZZYCT.js} +78 -56
  151. package/dist/{statusline-fast-YVHG6ZLX.js → statusline-fast-E7RWVREA.js} +4 -4
  152. package/dist/sync-cmd-EO4TP2K7.js +42 -0
  153. package/dist/update-steps-46FCWHJZ.js +79 -0
  154. package/dist/{watch-6NRBX6VE.js → watch-EG6MYI3O.js} +28 -28
  155. package/dist/{work-claim-cmd-SLVX2N4L.js → work-claim-cmd-MPH5HFLT.js} +26 -26
  156. package/dist/work-cmd-PKEAVXJC.js +31 -0
  157. package/dist/work-comment-cmd-7IEOLOOK.js +32 -0
  158. package/dist/{work-demo-cmd-SZJIKB5J.js → work-demo-cmd-GKMBBMMM.js} +20 -20
  159. package/dist/{work-launch-LEQ2MPM3.js → work-launch-TTGSHLY4.js} +3 -3
  160. package/dist/{work-logs-cmd-MRFSBMJM.js → work-logs-cmd-44ZOKO5E.js} +20 -20
  161. package/dist/{work-open-pr-cmd-N7GK7FUQ.js → work-open-pr-cmd-YYQLQ7DN.js} +22 -22
  162. package/dist/work-pr-cmd-ILCIO22W.js +32 -0
  163. package/dist/work-proofs-cmd-S7HZNVFC.js +35 -0
  164. package/dist/{work-proofs-record-JD4DNZUW.js → work-proofs-record-RJMR37XG.js} +34 -34
  165. package/dist/{work-stop-cmd-M6RIGF7S.js → work-stop-cmd-5VPW7HOZ.js} +20 -20
  166. package/package.json +1 -1
  167. package/dist/agent-setup-IVXRBFVV.js +0 -32
  168. package/dist/connect-cmd-JFGDHFLA.js +0 -27
  169. package/dist/emit-artifact-cmd-TZTVQCFT.js +0 -43
  170. package/dist/emit-cmd-4G3443OJ.js +0 -16
  171. package/dist/emit-criteria-cmd-WH7JB4RQ.js +0 -33
  172. package/dist/emit-demo-cmd-DNUVG5N7.js +0 -47
  173. package/dist/emit-finding-cmd-X5CBH4ZA.js +0 -34
  174. package/dist/emit-step-cmd-IUXZZYKO.js +0 -33
  175. package/dist/find-unit-QYD2FMCP.js +0 -19
  176. package/dist/fleet-readiness-F65CKZY5.js +0 -28
  177. package/dist/governing-source-JFCTQXYK.js +0 -38
  178. package/dist/host-checks-HC4XXGAD.js +0 -77
  179. package/dist/init-JVKJTJNM.js +0 -56
  180. package/dist/login-browser-Q25ZNSQ3.js +0 -13
  181. package/dist/loop-GBTANKUW.js +0 -87
  182. package/dist/machine-OQOHEMJB.js +0 -56
  183. package/dist/session-sender-U2CTD7EX.js +0 -43
  184. package/dist/sync-cmd-EBJQ5LMH.js +0 -42
  185. package/dist/update-steps-HMSVBDKH.js +0 -78
  186. package/dist/work-cmd-VSHZCXHQ.js +0 -31
  187. package/dist/work-comment-cmd-3DCL7VHN.js +0 -32
  188. package/dist/work-pr-cmd-HD5OIHUU.js +0 -32
  189. package/dist/work-proofs-cmd-GFGENBGN.js +0 -35
@@ -1,25 +1,25 @@
1
1
  #!/usr/bin/env node
2
2
  import { createRequire } from 'node:module';
3
- import { uploadSpooledSteps } from './chunk-MCPCOKHN.js';
4
- import { LaunchFilter } from './chunk-ESVW4MJY.js';
3
+ import { uploadSpooledSteps } from './chunk-W74HQLLZ.js';
4
+ import { LaunchFilter } from './chunk-AAGU5FJF.js';
5
5
  import { RepoFilter } from './chunk-TBT347UY.js';
6
- import { C } from './chunk-ANPNT6PM.js';
7
- import { migrateLegacyArtifactSidecars, planArtifactUpload, artifactsStatePath, sanitizeTerminal, acquireArtifactSpoolLock, artifactBlobsDir, resolveArtifactTurnIndex, isArtifactTombstoned, ARTIFACT_RETRY_MAX_AGE_MS, writeArtifactSpoolState, reclaimUnneededArtifactBlobs, neededArtifactShas } from './chunk-VEVNGDTP.js';
8
- import { cliFetch, resolveGatewayCredentials, defaultFetch, unauthorizedMessage } from './chunk-3KGXXTMN.js';
9
- import { readCloudConfig, cloudConfigPath, writeCloudConfig } from './chunk-PJDQPF5N.js';
10
- import { signerFor, signRunnerRequest } from './chunk-5TXQFZHY.js';
11
- import { writeSyncStatus, spoolDir } from './chunk-V2S2WRGD.js';
12
- import { readLatestProvenanceForSession, readContextProvenance } from './chunk-ZJSNLVCE.js';
13
- import { hookExecSpoolPath } from './chunk-2O5KA67H.js';
6
+ import { C } from './chunk-2AM6Z5BP.js';
7
+ import { migrateLegacyArtifactSidecars, planArtifactUpload, artifactsStatePath, sanitizeTerminal, acquireArtifactSpoolLock, artifactBlobsDir, resolveArtifactTurnIndex, isArtifactTombstoned, ARTIFACT_RETRY_MAX_AGE_MS, writeArtifactSpoolState, reclaimUnneededArtifactBlobs, neededArtifactShas } from './chunk-PDK35AR4.js';
8
+ import { cliFetch, resolveGatewayCredentials, defaultFetch, unauthorizedMessage } from './chunk-GBMTKV5B.js';
9
+ import { readCloudConfig, cloudConfigPath, writeCloudConfig } from './chunk-HWVMRETT.js';
10
+ import { signerFor, signRunnerRequest } from './chunk-XU5BNWX7.js';
11
+ import { writeSyncStatus, spoolDir } from './chunk-HS5QEIJT.js';
12
+ import { readLatestProvenanceForSession, readContextProvenance } from './chunk-545P7JY7.js';
13
+ import { hookExecSpoolPath } from './chunk-FUJUFLDC.js';
14
14
  import { applyReportedCost } from './chunk-BKO6JEZI.js';
15
15
  import { readRepoConnection, findGitDirs } from './chunk-BJ3KTMDH.js';
16
- import { setCustomScrubbers, setLocalIdentity, tailTranscript, enrichSessionRepo, scanAll, setRepoRoot, resolveRepoIdentity, sessionIdFromPath, scrubDeep, SOURCE_ADAPTERS } from './chunk-GH2HEEOH.js';
17
- import { readLaunchSpoolState, launchStatusIsDecisive, launchedItemsBySession, launchesPath } from './chunk-T2Q7ISPE.js';
18
- import { cliInvocation } from './chunk-CRB3POP4.js';
19
- import { removeJournalHooks } from './chunk-TUSYOL2O.js';
20
- import { CAPTURE_TIERS, inferArtifactKind, bannedPathsForTier, downconvertSession, isHumanUserTurn, turnCountBound, EVENT_TYPES } from './chunk-IXRUVR25.js';
21
- import { homeFromEnv } from './chunk-VNVZDWO3.js';
22
- import { SCRUB_ENV_VARIABLE } from './chunk-YLPJOUVF.js';
16
+ import { setCustomScrubbers, setLocalIdentity, tailTranscript, enrichSessionRepo, scanAll, setRepoRoot, resolveRepoIdentity, sessionIdFromPath, scrubDeep, SOURCE_ADAPTERS } from './chunk-TV2OQUWE.js';
17
+ import { readLaunchSpoolState, launchStatusIsDecisive, launchedItemsBySession, launchesPath } from './chunk-5WYT3PPE.js';
18
+ import { cliInvocation } from './chunk-FZKNTIOJ.js';
19
+ import { removeJournalHooks } from './chunk-CJPTUU2E.js';
20
+ import { CAPTURE_TIERS, inferArtifactKind, bannedPathsForTier, downconvertSession, isHumanUserTurn, turnCountBound, EVENT_TYPES } from './chunk-YTTESG7K.js';
21
+ import { homeFromEnv, spoolHomeFromEnv } from './chunk-352DHUTP.js';
22
+ import { SCRUB_ENV_VARIABLE } from './chunk-GANAOCHR.js';
23
23
  import { dirname, basename, join, sep } from 'path';
24
24
  import { statSync, readFileSync, readdirSync, mkdirSync, writeFileSync, renameSync, existsSync, rmSync } from 'fs';
25
25
  import { execFileSync } from 'child_process';
@@ -1111,6 +1111,7 @@ function parseWorkItemNumber(raw) {
1111
1111
  async function runSyncInner(opts, stats) {
1112
1112
  const envVars = opts.env ?? process.env;
1113
1113
  const home = opts.home ?? homeFromEnv(envVars);
1114
+ const artifactHome = opts.home ?? spoolHomeFromEnv(envVars, home);
1114
1115
  const fileConfig = readCloudConfig(home);
1115
1116
  const resolved = resolveGatewayCredentials({ ...opts, home, env: envVars });
1116
1117
  stats.url = resolved.url;
@@ -1177,12 +1178,12 @@ async function runSyncInner(opts, stats) {
1177
1178
  `
1178
1179
  );
1179
1180
  }
1180
- if (!dryRun) migrateLegacyArtifactSidecars(home);
1181
- const artifactPlan = planArtifactUpload({ home });
1181
+ if (!dryRun) migrateLegacyArtifactSidecars(artifactHome);
1182
+ const artifactPlan = planArtifactUpload({ home: artifactHome });
1182
1183
  if (!opts.quiet) {
1183
1184
  if (artifactPlan.corrupt) {
1184
1185
  process.stderr.write(
1185
- `${C.yellow}!${C.reset} artifact spool state at ${artifactsStatePath(home)} is corrupt \u2014 treating it as empty; a record's saved disposition may be forgotten (a safe, if wasteful, re-upload for anything already synced)
1186
+ `${C.yellow}!${C.reset} artifact spool state at ${artifactsStatePath(artifactHome)} is corrupt \u2014 treating it as empty; a record's saved disposition may be forgotten (a safe, if wasteful, re-upload for anything already synced)
1186
1187
  `
1187
1188
  );
1188
1189
  }
@@ -1621,7 +1622,7 @@ ${C.yellow}!${C.reset} batch ${shippedBatches + 1}/${batches.length} accounting
1621
1622
  let artifactsUploaded;
1622
1623
  let artifactsHeld;
1623
1624
  let uploadedArtifacts;
1624
- const artifactLock = combinedRecords.length > 0 || artifactPlan.held.length > 0 ? await acquireArtifactSpoolLock(home, { waitMs: opts.artifactLockWaitMs }) : void 0;
1625
+ const artifactLock = combinedRecords.length > 0 || artifactPlan.held.length > 0 ? await acquireArtifactSpoolLock(artifactHome, { waitMs: opts.artifactLockWaitMs }) : void 0;
1625
1626
  if (artifactLock !== void 0 && !artifactLock.ok) {
1626
1627
  artifactsUploaded = 0;
1627
1628
  artifactsHeld = combinedRecords.length + artifactPlan.held.length;
@@ -1635,7 +1636,7 @@ ${C.yellow}!${C.reset} batch ${shippedBatches + 1}/${batches.length} accounting
1635
1636
  }
1636
1637
  const releaseArtifactLock = artifactLock?.ok === true ? artifactLock.release : () => {
1637
1638
  };
1638
- const livePlan = artifactLock?.ok === true ? planArtifactUpload({ home }) : void 0;
1639
+ const livePlan = artifactLock?.ok === true ? planArtifactUpload({ home: artifactHome }) : void 0;
1639
1640
  if (livePlan !== void 0) {
1640
1641
  const artifactEndpoint = new URL("/v1/artifacts", url).toString();
1641
1642
  const nowMs = Date.now();
@@ -1671,7 +1672,7 @@ ${C.yellow}!${C.reset} batch ${shippedBatches + 1}/${batches.length} accounting
1671
1672
  }
1672
1673
  let blobData;
1673
1674
  try {
1674
- blobData = readFileSync(join(artifactBlobsDir(home), record.sha256));
1675
+ blobData = readFileSync(join(artifactBlobsDir(artifactHome), record.sha256));
1675
1676
  } catch {
1676
1677
  state.set(record.artifactId, {
1677
1678
  state: "dropped",
@@ -1682,7 +1683,7 @@ ${C.yellow}!${C.reset} batch ${shippedBatches + 1}/${batches.length} accounting
1682
1683
  });
1683
1684
  failedOrDroppedThisRun.add(record.artifactId);
1684
1685
  warn(
1685
- `artifact ${name} (${record.artifactId}): blob missing from the spool \u2014 ${join(artifactBlobsDir(home), record.sha256)} does not exist; dropping the record`
1686
+ `artifact ${name} (${record.artifactId}): blob missing from the spool \u2014 ${join(artifactBlobsDir(artifactHome), record.sha256)} does not exist; dropping the record`
1686
1687
  );
1687
1688
  droppedCount += 1;
1688
1689
  continue;
@@ -1692,7 +1693,7 @@ ${C.yellow}!${C.reset} batch ${shippedBatches + 1}/${batches.length} accounting
1692
1693
  let replaces = record.replaces;
1693
1694
  if (record.replacesTargets === void 0 && replaces !== void 0) {
1694
1695
  const targetKnownUploaded = state.get(replaces)?.state === "uploaded";
1695
- const targetTombstonedUnconfirmed = !targetKnownUploaded && isArtifactTombstoned(replaces, home);
1696
+ const targetTombstonedUnconfirmed = !targetKnownUploaded && isArtifactTombstoned(replaces, artifactHome);
1696
1697
  if (targetTombstonedUnconfirmed || failedOrDroppedThisRun.has(replaces)) replaces = void 0;
1697
1698
  }
1698
1699
  const request = {
@@ -1840,14 +1841,14 @@ ${C.yellow}!${C.reset} batch ${shippedBatches + 1}/${batches.length} accounting
1840
1841
  }
1841
1842
  }
1842
1843
  }
1843
- const persisted = writeArtifactSpoolState(state, home);
1844
+ const persisted = writeArtifactSpoolState(state, artifactHome);
1844
1845
  if (!persisted && !opts.quiet) {
1845
1846
  process.stderr.write(
1846
- `${C.yellow}!${C.reset} failed to persist ${artifactsStatePath(home)} \u2014 this run's artifact progress may be re-attempted next sync (safe: uploads are idempotent on the client artifact id)
1847
+ `${C.yellow}!${C.reset} failed to persist ${artifactsStatePath(artifactHome)} \u2014 this run's artifact progress may be re-attempted next sync (safe: uploads are idempotent on the client artifact id)
1847
1848
  `
1848
1849
  );
1849
1850
  }
1850
- reclaimUnneededArtifactBlobs(home, neededArtifactShas(home, state));
1851
+ reclaimUnneededArtifactBlobs(artifactHome, neededArtifactShas(artifactHome, state));
1851
1852
  releaseArtifactLock();
1852
1853
  if (unauthorized) {
1853
1854
  failureContext();
@@ -1,7 +1,7 @@
1
1
  #!/usr/bin/env node
2
2
  import { createRequire } from 'node:module';
3
3
  import { isSameProcess } from './chunk-JBJTC3UU.js';
4
- import { RUNNER_DIR_MODE, RUNNER_FILE_MODE } from './chunk-S6UM3N4R.js';
4
+ import { RUNNER_DIR_MODE, RUNNER_FILE_MODE } from './chunk-YQHUCOUL.js';
5
5
  import { existsSync, readFileSync, mkdirSync, writeFileSync, rmSync } from 'fs';
6
6
  import { dirname } from 'path';
7
7
 
@@ -1,13 +1,13 @@
1
1
  #!/usr/bin/env node
2
2
  import { createRequire } from 'node:module';
3
- import { DEFAULT_DASHBOARD } from './chunk-CKDSPW35.js';
4
- import { sanitizeTerminal } from './chunk-VEVNGDTP.js';
5
- import { isAgentsMdLayout } from './chunk-ARL6X6Y4.js';
6
- import { cliFetch, resolveGatewayCredentials } from './chunk-3KGXXTMN.js';
7
- import { readCloudConfig } from './chunk-PJDQPF5N.js';
3
+ import { DEFAULT_DASHBOARD } from './chunk-ZI2E4YMY.js';
4
+ import { sanitizeTerminal } from './chunk-PDK35AR4.js';
5
+ import { isAgentsMdLayout } from './chunk-62TMOXQN.js';
6
+ import { cliFetch, resolveGatewayCredentials } from './chunk-GBMTKV5B.js';
7
+ import { readCloudConfig } from './chunk-HWVMRETT.js';
8
8
  import { findGitDirs, writeRepoConnection, readRepoConnection } from './chunk-BJ3KTMDH.js';
9
- import { remoteLookupFailed } from './chunk-GH2HEEOH.js';
10
- import { cliInvocation } from './chunk-CRB3POP4.js';
9
+ import { remoteLookupFailed } from './chunk-TV2OQUWE.js';
10
+ import { cliInvocation } from './chunk-FZKNTIOJ.js';
11
11
  import { execFileSync } from 'child_process';
12
12
  import { lstatSync } from 'fs';
13
13
  import { join, relative } from 'path';
@@ -1,16 +1,16 @@
1
1
  #!/usr/bin/env node
2
2
  import { createRequire } from 'node:module';
3
- import { runEmit } from './chunk-OKJXZXYH.js';
4
- import { addStdioMcpEntryIfAbsent, addDocsMcpEntryIfAbsent, DOCS_MCP_SERVER_NAME } from './chunk-KT4CN6OU.js';
5
- import { installStarterPack } from './chunk-54LIUIZL.js';
6
- import { C } from './chunk-ANPNT6PM.js';
7
- import { AGENTS_MD_LAYOUT, declareAgentsMdLayout, linkClaudeSkills, SKILLS_LINK_PATH, describeSkillsLink, isAgentsMdLayout, holdsTodaysLayoutSources, discoverOuterlayerPaths } from './chunk-ARL6X6Y4.js';
8
- import { resolveGitCommonDir, defaultGitRunner } from './chunk-UZEIBWTP.js';
9
- import { loadTemplateFiles, loadMaintainedFiles, skillDir, AGENTS_SKILLS_BASE } from './chunk-HH3BQG65.js';
10
- import { cliInvocation } from './chunk-CRB3POP4.js';
11
- import { linkedAgentsPath } from './chunk-RQ3GCCHH.js';
3
+ import { runEmit } from './chunk-PUSCE544.js';
4
+ import { addStdioMcpEntryIfAbsent, addDocsMcpEntryIfAbsent, DOCS_MCP_SERVER_NAME } from './chunk-OHQMGLJP.js';
5
+ import { installStarterPack } from './chunk-XGSJNXH2.js';
6
+ import { C } from './chunk-2AM6Z5BP.js';
7
+ import { AGENTS_MD_LAYOUT, declareAgentsMdLayout, linkClaudeSkills, SKILLS_LINK_PATH, describeSkillsLink, isAgentsMdLayout, holdsTodaysLayoutSources, discoverOuterlayerPaths } from './chunk-62TMOXQN.js';
8
+ import { resolveGitCommonDir, defaultGitRunner } from './chunk-2OE4BZRF.js';
9
+ import { loadTemplateFiles, loadMaintainedFiles, skillDir, AGENTS_SKILLS_BASE } from './chunk-UPRZREBO.js';
10
+ import { cliInvocation } from './chunk-FZKNTIOJ.js';
11
+ import { linkedAgentsPath } from './chunk-JXXMOAJG.js';
12
12
  import { cloneIsGoverned } from './chunk-YQR6E6OV.js';
13
- import { generatedHeaderSource } from './chunk-2EEW6FJN.js';
13
+ import { generatedHeaderSource } from './chunk-5FWBAM6O.js';
14
14
  import { execFileSync } from 'child_process';
15
15
  import { existsSync, mkdirSync, writeFileSync } from 'fs';
16
16
  import { join, dirname } from 'path';
@@ -1,6 +1,6 @@
1
1
  #!/usr/bin/env node
2
2
  import { createRequire } from 'node:module';
3
- import { homeFromEnv } from './chunk-VNVZDWO3.js';
3
+ import { homeFromEnv } from './chunk-352DHUTP.js';
4
4
  import { execFileSync } from 'child_process';
5
5
  import { readdirSync, readFileSync, existsSync, unlinkSync } from 'fs';
6
6
  import { join, isAbsolute, resolve } from 'path';
@@ -1,13 +1,13 @@
1
1
  #!/usr/bin/env node
2
2
  import { createRequire } from 'node:module';
3
- import { toolsDockerfile } from './chunk-T3XPLCJG.js';
4
- import { runnerLabelValue } from './chunk-P2PNBDUT.js';
3
+ import { toolsDockerfile } from './chunk-XBECMHJW.js';
4
+ import { claimPidFile, RunnerAlreadyRunningError, releasePidFile } from './chunk-AUVJMR3P.js';
5
+ import { startTimeOf } from './chunk-JBJTC3UU.js';
6
+ import { runnerLabelValue } from './chunk-NM3L4JBB.js';
5
7
  import { RecipeError, locateRecipe, readRecipe, assertBuildable, writeSanitizedRecipe, classifyProperties, SANITIZED_NAME } from './chunk-CM4J53WZ.js';
6
8
  import { UNIVERSAL_IMAGE_DIGEST, UNIVERSAL_IMAGE_REPOSITORY, UNIVERSAL_IMAGE_SOURCE, CLAUDE_CODE_VERSION, NODE_IMAGE, UNIVERSAL_IMAGE, MEDIA_PINS, TINI_VERSION, GH_VERSION } from './chunk-D3CT6XQ4.js';
7
- import { claimPidFile, RunnerAlreadyRunningError, releasePidFile } from './chunk-SAAVZ2BX.js';
8
- import { startTimeOf } from './chunk-JBJTC3UU.js';
9
- import { RUNNER_DIR_MODE, RUNNER_FILE_MODE, repoCacheDir, imagesDir, imageBuildLogsDir, attemptStamp, runnerDir, rootfsPathFor } from './chunk-S6UM3N4R.js';
10
- import { withGitConfig, tokenHeader } from './chunk-YLPJOUVF.js';
9
+ import { RUNNER_DIR_MODE, RUNNER_FILE_MODE, repoCacheDir, imagesDir, imageBuildLogsDir, attemptStamp, orgStore, rootfsPathFor } from './chunk-YQHUCOUL.js';
10
+ import { withGitConfig, tokenHeader } from './chunk-GANAOCHR.js';
11
11
  import { mkdirSync, rmSync, writeFileSync, existsSync, mkdtempSync, cpSync, readFileSync, readdirSync, lstatSync, readlinkSync } from 'fs';
12
12
  import { tmpdir } from 'os';
13
13
  import { dirname, join } from 'path';
@@ -310,9 +310,10 @@ async function prepareImageBuild(opts) {
310
310
  const now = opts.now ?? (() => /* @__PURE__ */ new Date());
311
311
  const claudeCodeVersion = opts.claudeCodeVersion ?? CLAUDE_CODE_VERSION;
312
312
  const nodeImage = opts.nodeImage ?? NODE_IMAGE;
313
- const cacheDir = repoCacheDir(opts.configPath, owner, name);
314
- const repoRecords = join(imagesDir(opts.configPath), owner, name);
315
- const logPath = join(imageBuildLogsDir(opts.configPath, owner, name), `${attemptStamp(now())}.log`);
313
+ const organizationId = opts.organizationId;
314
+ const cacheDir = repoCacheDir(opts.configPath, owner, name, organizationId);
315
+ const repoRecords = join(imagesDir(opts.configPath, organizationId), owner, name);
316
+ const logPath = join(imageBuildLogsDir(opts.configPath, owner, name, organizationId), `${attemptStamp(now())}.log`);
316
317
  const lockPath = join(repoRecords, LOCK_NAME);
317
318
  const self = { pid: process.pid, start: startTimeOf(process.pid) ?? "" };
318
319
  mkdirSync(repoRecords, { recursive: true, mode: RUNNER_DIR_MODE });
@@ -336,8 +337,9 @@ async function prepareImageBuild(opts) {
336
337
  const recipe = readRecipe(checkout.dir, location);
337
338
  assertBuildable(checkout.dir, location, recipe);
338
339
  const shared = location.kind === "default";
339
- const imageRepository = shared ? SHARED_REPOSITORY : repository;
340
- const records = shared ? join(imagesDir(opts.configPath), SHARED_OWNER, SHARED_NAME) : repoRecords;
340
+ const scope = organizationId === void 0 ? "" : `${organizationId}/`;
341
+ const imageRepository = `${scope}${shared ? SHARED_REPOSITORY : repository}`;
342
+ const records = shared ? join(imagesDir(opts.configPath, organizationId), SHARED_OWNER, SHARED_NAME) : repoRecords;
341
343
  if (shared) {
342
344
  mkdirSync(records, { recursive: true, mode: RUNNER_DIR_MODE });
343
345
  const sharedLock = join(records, LOCK_NAME);
@@ -360,7 +362,7 @@ async function prepareImageBuild(opts) {
360
362
  name,
361
363
  repoRecords: records,
362
364
  imageRepository,
363
- tagName: shared ? SHARED_TAG_NAME : repository,
365
+ tagName: `${scope}${shared ? SHARED_TAG_NAME : repository}`,
364
366
  recordDir,
365
367
  checkout,
366
368
  location,
@@ -494,8 +496,8 @@ async function buildRepositoryImage(opts, ports) {
494
496
  report = { ...report, base };
495
497
  }
496
498
  const removed = [];
497
- if (toolsBuilt) removed.push(...await prune(host, imageRepository, repoRecords, opts.keep ?? KEEP_BUILD_IMAGES, runnerDir(opts.configPath), runnerLabel));
498
- if (universal) removed.push(...await prune(host, repository, join(imagesDir(opts.configPath), prepared.owner, prepared.name), 0, runnerDir(opts.configPath), runnerLabel));
499
+ if (toolsBuilt) removed.push(...await prune(host, imageRepository, repoRecords, opts.keep ?? KEEP_BUILD_IMAGES, orgStore(opts.configPath, opts.organizationId), runnerLabel));
500
+ if (universal) removed.push(...await prune(host, `${opts.organizationId === void 0 ? "" : `${opts.organizationId}/`}${repository}`, join(imagesDir(opts.configPath, opts.organizationId), prepared.owner, prepared.name), 0, orgStore(opts.configPath, opts.organizationId), runnerLabel));
499
501
  return {
500
502
  reused: !recipeBuilt && !toolsBuilt,
501
503
  recipeBuilt,
@@ -4,6 +4,6 @@ import { createRequire } from 'node:module';
4
4
  createRequire(import.meta.url);
5
5
 
6
6
  // src/runner/protocol.ts
7
- var RUNNER_PROTOCOL = 33;
7
+ var RUNNER_PROTOCOL = 35;
8
8
 
9
9
  export { RUNNER_PROTOCOL };
@@ -1,8 +1,8 @@
1
1
  #!/usr/bin/env node
2
2
  import { createRequire } from 'node:module';
3
- import { DEFAULT_UNIT_NAME } from './chunk-4YD7N6V3.js';
4
- import { RUNNER_FILE_MODE } from './chunk-S6UM3N4R.js';
5
- import { claudeEnvPath, withoutCredentialLines, parseRunnerEnv } from './chunk-YLPJOUVF.js';
3
+ import { DEFAULT_UNIT_NAME } from './chunk-TKTVKEES.js';
4
+ import { RUNNER_FILE_MODE } from './chunk-YQHUCOUL.js';
5
+ import { claudeEnvPath, withoutCredentialLines, parseRunnerEnv } from './chunk-GANAOCHR.js';
6
6
  import { existsSync, readFileSync, writeFileSync, renameSync, rmSync } from 'fs';
7
7
  import { join, dirname } from 'path';
8
8
 
@@ -1,7 +1,7 @@
1
1
  #!/usr/bin/env node
2
2
  import { createRequire } from 'node:module';
3
- import { decodeWrappedCommand } from './chunk-URIZRCRY.js';
4
- import { homeFromEnv } from './chunk-VNVZDWO3.js';
3
+ import { decodeWrappedCommand } from './chunk-KYDEBGJG.js';
4
+ import { homeFromEnv } from './chunk-352DHUTP.js';
5
5
  import { readFileSync, mkdirSync, appendFileSync, writeFileSync } from 'fs';
6
6
  import { spawn } from 'child_process';
7
7
  import { randomUUID, createHash } from 'crypto';
@@ -1,6 +1,6 @@
1
1
  #!/usr/bin/env node
2
2
  import { createRequire } from 'node:module';
3
- import { homeFromEnv } from './chunk-VNVZDWO3.js';
3
+ import { homeFromEnv } from './chunk-352DHUTP.js';
4
4
  import { join, sep } from 'path';
5
5
  import { fileURLToPath } from 'url';
6
6
 
@@ -887,11 +887,16 @@ function isMiseVariableAllowed(name) {
887
887
  function withMiseVariables(env, variables) {
888
888
  if (variables === void 0) return env;
889
889
  const passed = { ...env.passed };
890
+ const literals = { ...env.literals };
890
891
  for (const [name, value] of Object.entries(variables)) {
892
+ if (name === "PATH") {
893
+ if (!(name in env.literals) && passed[name] === void 0) literals[name] = value;
894
+ continue;
895
+ }
891
896
  if (!isMiseVariableAllowed(name) || name in env.literals || passed[name] !== void 0) continue;
892
897
  passed[name] = value;
893
898
  }
894
- return { ...env, passed };
899
+ return { ...env, literals, passed };
895
900
  }
896
901
  var NO_VARIABLES = [];
897
902
  function buildEnvironment(input) {
@@ -1,12 +1,12 @@
1
1
  #!/usr/bin/env node
2
2
  import { createRequire } from 'node:module';
3
- import { readCloudConfigStrict, readCloudConfig, cloudConfigPath } from './chunk-PJDQPF5N.js';
4
- import { signRunnerRequest, signerFor } from './chunk-5TXQFZHY.js';
3
+ import { readCloudConfigStrict, readCloudConfig, cloudConfigPath } from './chunk-HWVMRETT.js';
4
+ import { signRunnerRequest, signerFor } from './chunk-XU5BNWX7.js';
5
5
  import { readRepoConnection, findGitDirs } from './chunk-BJ3KTMDH.js';
6
- import { PLAIN_VERSION, recordCliVersion, removeRecordedVersion } from './chunk-5BHIBJDA.js';
6
+ import { PLAIN_VERSION, recordCliVersion, removeRecordedVersion } from './chunk-OLM2TIOW.js';
7
7
  import { resolvePackageVersion } from './chunk-RA3O54FC.js';
8
- import { cliInvocation } from './chunk-CRB3POP4.js';
9
- import { homeFromEnv } from './chunk-VNVZDWO3.js';
8
+ import { cliInvocation } from './chunk-FZKNTIOJ.js';
9
+ import { homeFromEnv } from './chunk-352DHUTP.js';
10
10
 
11
11
  createRequire(import.meta.url);
12
12
 
@@ -1,9 +1,9 @@
1
1
  #!/usr/bin/env node
2
2
  import { createRequire } from 'node:module';
3
- import { TUNNEL_PORT, BRIDGE_ADDRESS, BRIDGE_CIDR } from './chunk-BBJ6BM5U.js';
4
- import { EXEC_PORT } from './chunk-ROQPDCRU.js';
3
+ import { TUNNEL_PORT, BRIDGE_ADDRESS, BRIDGE_CIDR } from './chunk-MKSZHT6S.js';
5
4
  import { startTimeOf } from './chunk-JBJTC3UU.js';
6
- import { RELAY_PORT } from './chunk-YLPJOUVF.js';
5
+ import { EXEC_PORT } from './chunk-UZGQT6OF.js';
6
+ import { RELAY_PORT } from './chunk-GANAOCHR.js';
7
7
  import { spawn, spawnSync } from 'child_process';
8
8
  import { symlinkSync, lstatSync, writeFileSync, chmodSync, mkdirSync, existsSync } from 'fs';
9
9
 
@@ -1,13 +1,13 @@
1
1
  #!/usr/bin/env node
2
2
  import { createRequire } from 'node:module';
3
- import { WorkCommandError, postJson } from './chunk-XDAMLX2L.js';
4
- import { defaultGitRunner, materializeContext, fetchControlPlaneCommit, lookupGoverningSource } from './chunk-UZEIBWTP.js';
5
- import { signingFetchFor } from './chunk-3KGXXTMN.js';
6
- import { signerFor } from './chunk-5TXQFZHY.js';
3
+ import { WorkCommandError, postJson } from './chunk-JQOET7TF.js';
4
+ import { defaultGitRunner, materializeContext, fetchControlPlaneCommit, lookupGoverningSource } from './chunk-2OE4BZRF.js';
5
+ import { signingFetchFor } from './chunk-GBMTKV5B.js';
6
+ import { signerFor } from './chunk-XU5BNWX7.js';
7
7
  import { unsupportedLayout, layoutRefusalReason, composeDelivery } from './chunk-FGF52V4V.js';
8
8
  import { SHIM_SCRIPT, GOVERNANCE_VARIABLE } from './chunk-HCVLP7XA.js';
9
9
  import { readDegraded, readContextManifest, readSourceCache } from './chunk-YQR6E6OV.js';
10
- import { SHIM_DIR, stagedContextDir, contextHomeDir, deliveryDir, keptContextDir } from './chunk-S6UM3N4R.js';
10
+ import { SHIM_DIR, stagedContextDir, contextHomeDir, deliveryDir, keptContextDir } from './chunk-YQHUCOUL.js';
11
11
  import { fstatSync, mkdirSync, writeFileSync, chmodSync, rmSync, cpSync, readFileSync, existsSync, lstatSync } from 'fs';
12
12
  import { relative, join, dirname } from 'path';
13
13
 
@@ -391,7 +391,7 @@ async function stageGovernedContext(input) {
391
391
  const result = await materializeContext({
392
392
  cwd: tree,
393
393
  sessionId: `build-${input.buildId}`,
394
- home: contextHomeDir(configPath),
394
+ home: contextHomeDir(configPath, input.organizationId),
395
395
  cloud: { url, apiKey, appId },
396
396
  fetchImpl: signingFetchFor(input.fetchImpl, configPath, apiKey),
397
397
  designationLookup: DESIGNATION_LOOKUP,
@@ -473,7 +473,7 @@ async function prefetchGovernedContext(input) {
473
473
  try {
474
474
  const fetched = await fetchControlPlaneCommit({
475
475
  git: input.git ?? defaultGitRunner,
476
- home: contextHomeDir(input.configPath),
476
+ home: contextHomeDir(input.configPath, input.organizationId),
477
477
  repository: source.repository,
478
478
  sha: source.sha,
479
479
  remoteUrl: input.controlPlaneUrl(source.repository),
@@ -1,13 +1,13 @@
1
1
  #!/usr/bin/env node
2
2
  import { createRequire } from 'node:module';
3
- import { appendContextProvenance } from './chunk-ZJSNLVCE.js';
3
+ import { appendContextProvenance } from './chunk-545P7JY7.js';
4
4
  import { CONTROL_PLANE_DIR_VARIABLE } from './chunk-HCVLP7XA.js';
5
5
  import { readRepoConnection, findGitDirs } from './chunk-BJ3KTMDH.js';
6
- import { updateNoticeContext, staleMachineCopiesContext } from './chunk-5BHIBJDA.js';
6
+ import { updateNoticeContext, staleMachineCopiesContext } from './chunk-OLM2TIOW.js';
7
7
  import { resolvePackageVersion } from './chunk-RA3O54FC.js';
8
- import { cliInvocation } from './chunk-CRB3POP4.js';
9
- import { deadHooksState, huskyPrepareScript, preparePackageManagerCommand } from './chunk-TUSYOL2O.js';
10
- import { homeFromEnv } from './chunk-VNVZDWO3.js';
8
+ import { cliInvocation } from './chunk-FZKNTIOJ.js';
9
+ import { deadHooksState, huskyPrepareScript, preparePackageManagerCommand } from './chunk-CJPTUU2E.js';
10
+ import { homeFromEnv } from './chunk-352DHUTP.js';
11
11
  import { readFileSync, mkdirSync, writeFileSync, renameSync, existsSync, readdirSync, unlinkSync, statSync, appendFileSync, opendirSync } from 'fs';
12
12
  import { spawn, execFileSync } from 'child_process';
13
13
  import { createHash } from 'crypto';
@@ -429,7 +429,7 @@ function hookErrorsContext(home, writtenBytes, seenBytes) {
429
429
  }
430
430
  async function handleWorkLaunch(sessionId, home, env, spawnImpl = spawnDetached, cwd = process.cwd()) {
431
431
  if (!sessionId || env.OUTERLAYER_WORK === void 0) return void 0;
432
- const { parseWorkItemEnv, appendLaunchRecord } = await import('./work-launch-LEQ2MPM3.js');
432
+ const { parseWorkItemEnv, appendLaunchRecord } = await import('./work-launch-TTGSHLY4.js');
433
433
  const parsed = parseWorkItemEnv(env.OUTERLAYER_WORK);
434
434
  if ("reason" in parsed) {
435
435
  logHookError(home, new Error(`OUTERLAYER_WORK ignored: ${parsed.reason}`));
@@ -467,7 +467,7 @@ async function handleWorkLaunch(sessionId, home, env, spawnImpl = spawnDetached,
467
467
  }
468
468
  async function missingRenewalHookContext(home, cwd) {
469
469
  try {
470
- const { settingsPath, readSettings, isOurHookCommand } = await import('./settings-3DBYKYQD.js');
470
+ const { settingsPath, readSettings, isOurHookCommand } = await import('./settings-XB2HYBKO.js');
471
471
  const userSettings = readSettings(settingsPath("user", { home }));
472
472
  const projectSettings = readSettings(settingsPath("project", { cwd }));
473
473
  if (userSettings === null && projectSettings === null) return void 0;
@@ -495,7 +495,7 @@ async function maybeRenewWorkLease(event, sessionId, home = homeFromEnv(), env =
495
495
  if (now - statSync(marker).mtimeMs < WORK_LEASE_RENEW_DEBOUNCE_MS) return;
496
496
  } catch {
497
497
  }
498
- const { parseWorkItemEnv } = await import('./work-launch-LEQ2MPM3.js');
498
+ const { parseWorkItemEnv } = await import('./work-launch-TTGSHLY4.js');
499
499
  const parsed = parseWorkItemEnv(env.OUTERLAYER_WORK);
500
500
  if ("reason" in parsed) return;
501
501
  writeFileSync(marker, String(now));
@@ -511,7 +511,7 @@ async function handleWorkSessionEnd(event, sessionId, _home = homeFromEnv(), env
511
511
  try {
512
512
  if (event !== "SessionEnd") return;
513
513
  if (!sessionId || env.OUTERLAYER_WORK === void 0) return;
514
- const { parseWorkItemEnv } = await import('./work-launch-LEQ2MPM3.js');
514
+ const { parseWorkItemEnv } = await import('./work-launch-TTGSHLY4.js');
515
515
  const parsed = parseWorkItemEnv(env.OUTERLAYER_WORK);
516
516
  if ("reason" in parsed) return;
517
517
  spawnImpl(
@@ -680,11 +680,11 @@ async function missingControlPlane(cwd, sessionId, home, env) {
680
680
  const dirs = findGitDirs(cwd);
681
681
  if (dirs === void 0) return void 0;
682
682
  if (existsSync(join(dirs.gitCommonDir, "outerlayer", "materialized.json")) || hasExcludeBlock(dirs.gitCommonDir)) {
683
- const { cleanupEarlierCopies } = await import('./context-cleanup-CEZSKNVL.js');
683
+ const { cleanupEarlierCopies } = await import('./context-cleanup-PASDUBGW.js');
684
684
  cleanupEarlierCopies(dirs);
685
685
  }
686
686
  if (!contextPossiblyGoverned(cwd, home)) return void 0;
687
- const { governanceOf } = await import('./control-plane-launch-3MBWPYWZ.js');
687
+ const { governanceOf } = await import('./control-plane-launch-FV5Q6GVJ.js');
688
688
  if (await governanceOf({ cwd, env, home }) !== "governed") return void 0;
689
689
  recordMissingContext(dirs, sessionId, home);
690
690
  const launcher = `${cliInvocation()} claude`;
@@ -1,6 +1,6 @@
1
1
  #!/usr/bin/env node
2
2
  import { createRequire } from 'node:module';
3
- import { homeFromEnv } from './chunk-VNVZDWO3.js';
3
+ import { homeFromEnv } from './chunk-352DHUTP.js';
4
4
  import { existsSync, readFileSync, mkdirSync, writeFileSync, chmodSync } from 'fs';
5
5
  import { join } from 'path';
6
6
 
@@ -1,13 +1,13 @@
1
1
  #!/usr/bin/env node
2
2
  import { createRequire } from 'node:module';
3
- import { resolveCredentials, postJson, getJson } from './chunk-XDAMLX2L.js';
3
+ import { resolveCredentials, postJson, getJson } from './chunk-JQOET7TF.js';
4
4
  import { detectActiveSession } from './chunk-IP7BIBXJ.js';
5
- import { C } from './chunk-ANPNT6PM.js';
6
- import { sanitizeTerminal } from './chunk-VEVNGDTP.js';
7
- import { defaultFetch } from './chunk-3KGXXTMN.js';
8
- import { resolveRepoIdentity } from './chunk-GH2HEEOH.js';
5
+ import { C } from './chunk-2AM6Z5BP.js';
6
+ import { sanitizeTerminal } from './chunk-PDK35AR4.js';
7
+ import { defaultFetch } from './chunk-GBMTKV5B.js';
8
+ import { resolveRepoIdentity } from './chunk-TV2OQUWE.js';
9
9
  import { parseTrackerNumber, trackerNumberError } from './chunk-WZBHBH3J.js';
10
- import { homeFromEnv } from './chunk-VNVZDWO3.js';
10
+ import { homeFromEnv } from './chunk-352DHUTP.js';
11
11
  import { randomUUID } from 'crypto';
12
12
 
13
13
  createRequire(import.meta.url);
@@ -1,17 +1,17 @@
1
1
  #!/usr/bin/env node
2
2
  import { createRequire } from 'node:module';
3
- import { launchRefusalForSession } from './chunk-ESVW4MJY.js';
3
+ import { launchRefusalForSession } from './chunk-AAGU5FJF.js';
4
4
  import { detectActiveSession, transcriptPathForSession } from './chunk-IP7BIBXJ.js';
5
- import { autoConnect } from './chunk-MRLJK4GZ.js';
6
- import { C } from './chunk-ANPNT6PM.js';
7
- import { resolveGatewayCredentials, defaultFetch, unauthorizedMessage } from './chunk-3KGXXTMN.js';
8
- import { readLatestProvenanceForSession } from './chunk-ZJSNLVCE.js';
9
- import { resolveRepoIdentity, defaultProjectsDir, findTranscripts, sessionIdFromPath, scrubText } from './chunk-GH2HEEOH.js';
10
- import { launchedItemForSession } from './chunk-T2Q7ISPE.js';
5
+ import { autoConnect } from './chunk-UGPJIKN4.js';
6
+ import { C } from './chunk-2AM6Z5BP.js';
7
+ import { resolveGatewayCredentials, defaultFetch, unauthorizedMessage } from './chunk-GBMTKV5B.js';
8
+ import { readLatestProvenanceForSession } from './chunk-545P7JY7.js';
9
+ import { resolveRepoIdentity, defaultProjectsDir, findTranscripts, sessionIdFromPath, scrubText } from './chunk-TV2OQUWE.js';
10
+ import { launchedItemForSession } from './chunk-5WYT3PPE.js';
11
11
  import { parseTrackerNumber, trackerNumberError } from './chunk-WZBHBH3J.js';
12
- import { cliInvocation } from './chunk-CRB3POP4.js';
13
- import { FindingBatchSchema, FindingsResponseSchema, SAME_PROBLEM_RULES } from './chunk-IXRUVR25.js';
14
- import { homeFromEnv } from './chunk-VNVZDWO3.js';
12
+ import { cliInvocation } from './chunk-FZKNTIOJ.js';
13
+ import { FindingBatchSchema, FindingsResponseSchema, SAME_PROBLEM_RULES } from './chunk-YTTESG7K.js';
14
+ import { homeFromEnv } from './chunk-352DHUTP.js';
15
15
  import { readFileSync, existsSync } from 'fs';
16
16
  import { join, dirname, basename } from 'path';
17
17
 
@@ -1,16 +1,16 @@
1
1
  #!/usr/bin/env node
2
2
  import { createRequire } from 'node:module';
3
3
  import { detectActiveSession } from './chunk-IP7BIBXJ.js';
4
- import { autoConnect } from './chunk-MRLJK4GZ.js';
5
- import { workPageUrl } from './chunk-HFOZTCTN.js';
6
- import { C } from './chunk-ANPNT6PM.js';
7
- import { sanitizeTerminal } from './chunk-VEVNGDTP.js';
8
- import { resolveGatewayCredentials, unauthorizedMessage, defaultFetch } from './chunk-3KGXXTMN.js';
9
- import { signRunnerRequest } from './chunk-5TXQFZHY.js';
4
+ import { autoConnect } from './chunk-UGPJIKN4.js';
5
+ import { workPageUrl } from './chunk-AVHPSB65.js';
6
+ import { C } from './chunk-2AM6Z5BP.js';
7
+ import { sanitizeTerminal } from './chunk-PDK35AR4.js';
8
+ import { resolveGatewayCredentials, unauthorizedMessage, defaultFetch } from './chunk-GBMTKV5B.js';
9
+ import { signRunnerRequest } from './chunk-XU5BNWX7.js';
10
10
  import { readRepoConnection } from './chunk-BJ3KTMDH.js';
11
- import { resolveRepoIdentity } from './chunk-GH2HEEOH.js';
11
+ import { resolveRepoIdentity } from './chunk-TV2OQUWE.js';
12
12
  import { parseTrackerNumber, trackerNumberError } from './chunk-WZBHBH3J.js';
13
- import { homeFromEnv } from './chunk-VNVZDWO3.js';
13
+ import { homeFromEnv } from './chunk-352DHUTP.js';
14
14
 
15
15
  createRequire(import.meta.url);
16
16
 
@@ -471,7 +471,7 @@ async function runWorkLinkSession(opts) {
471
471
  return await linkSession(opts);
472
472
  } catch (err) {
473
473
  if (opts.logFailures) {
474
- const { logHookError } = await import('./hook-fast-GOH4T6SN.js');
474
+ const { logHookError } = await import('./hook-fast-5PNO5HRO.js');
475
475
  const reason = err instanceof Error ? err.message : String(err);
476
476
  logHookError(opts.home ?? homeFromEnv(opts.env ?? process.env), new Error(`work link-session #${opts.number} failed: ${reason}`));
477
477
  }
@@ -1,8 +1,8 @@
1
1
  #!/usr/bin/env node
2
2
  import { createRequire } from 'node:module';
3
3
  import { readContextManifest, removeContextManifest } from './chunk-YQR6E6OV.js';
4
- import { removePreCommitGuardHook } from './chunk-TUSYOL2O.js';
5
- import { CONTEXT_PIN_FILENAME } from './chunk-2EEW6FJN.js';
4
+ import { removePreCommitGuardHook } from './chunk-CJPTUU2E.js';
5
+ import { CONTEXT_PIN_FILENAME } from './chunk-5FWBAM6O.js';
6
6
  import { execFileSync } from 'child_process';
7
7
  import { lstatSync, existsSync, unlinkSync, readdirSync, rmdirSync, readFileSync, mkdirSync, writeFileSync } from 'fs';
8
8
  import { join, dirname, isAbsolute } from 'path';
@@ -1,6 +1,6 @@
1
1
  #!/usr/bin/env node
2
2
  import { createRequire } from 'node:module';
3
- import { homeFromEnv } from './chunk-VNVZDWO3.js';
3
+ import { homeFromEnv } from './chunk-352DHUTP.js';
4
4
  import { existsSync, readFileSync, mkdirSync, copyFileSync, writeFileSync } from 'fs';
5
5
  import { join, dirname, isAbsolute } from 'path';
6
6
 
@@ -1,7 +1,7 @@
1
1
  #!/usr/bin/env node
2
2
  import { createRequire } from 'node:module';
3
- import { escapeUnitPath, UNIT_MARKER, DEFAULT_UNIT_NAME } from './chunk-4YD7N6V3.js';
4
- import { inspectService, realInspectProbes } from './chunk-YLPJOUVF.js';
3
+ import { escapeUnitPath, UNIT_MARKER, DEFAULT_UNIT_NAME } from './chunk-TKTVKEES.js';
4
+ import { inspectService, realInspectProbes } from './chunk-GANAOCHR.js';
5
5
  import { realpathSync, readFileSync, readdirSync } from 'fs';
6
6
  import { resolve, dirname, join } from 'path';
7
7