@outerlayer/cli 0.36.0-next.20261101174803 → 0.36.0-next.20261102135508

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 (206) hide show
  1. package/dist/agent-setup-Q3HDN23U.js +39 -0
  2. package/dist/agent-subcommand-Z6SOLWZW.js +25 -0
  3. package/dist/bridge-4KPODDN7.js +15 -0
  4. package/dist/build-KYXFZQ33.js +23 -0
  5. package/dist/build-disk-W6AL5WHI.js +20 -0
  6. package/dist/build-info.json +1 -1
  7. package/dist/builder-IMNOEYV7.js +19 -0
  8. package/dist/caller-NLRE272L.js +22 -0
  9. package/dist/{check-K4RVAP4L.js → check-WWX32IGY.js} +78 -74
  10. package/dist/{chunk-MKSZHT6S.js → chunk-2YC3TXWX.js} +1 -1
  11. package/dist/{chunk-QIOTIQWD.js → chunk-3UFX6KH2.js} +12 -11
  12. package/dist/{chunk-F2LPX2HS.js → chunk-3YEPLVNW.js} +8 -8
  13. package/dist/chunk-4DLJ343I.js +38 -0
  14. package/dist/{chunk-5WYT3PPE.js → chunk-4OD45RBP.js} +4 -1
  15. package/dist/{chunk-H7SKHAUE.js → chunk-4XXBV37R.js} +6 -6
  16. package/dist/{chunk-XNBUZGRO.js → chunk-6B3V6EGQ.js} +11 -9
  17. package/dist/{chunk-O36YAH2G.js → chunk-6HDXRDC5.js} +4 -4
  18. package/dist/chunk-6JLYU322.js +68 -0
  19. package/dist/{chunk-5GHJFETA.js → chunk-6KH3NMIT.js} +3010 -1196
  20. package/dist/{chunk-SPXVFFQV.js → chunk-AQE6E54X.js} +10 -9
  21. package/dist/{chunk-LGV5N5DG.js → chunk-ATKCHMFD.js} +1 -1
  22. package/dist/{chunk-7J7HRYZ3.js → chunk-B2P72DAE.js} +1 -1
  23. package/dist/{chunk-LEHBDEUG.js → chunk-B36NSEUM.js} +4 -5
  24. package/dist/{chunk-B62TYDP2.js → chunk-B5SWBFVE.js} +5 -4
  25. package/dist/chunk-BSPJI5T7.js +28 -0
  26. package/dist/{chunk-VJYSPH2J.js → chunk-BUYXEU7J.js} +26 -21
  27. package/dist/{chunk-CIUD3436.js → chunk-BZSJ77MO.js} +1 -1
  28. package/dist/{chunk-OEBFKPHK.js → chunk-CDG475ZP.js} +11 -11
  29. package/dist/{chunk-AGKQEOFS.js → chunk-CSBW4LGL.js} +54 -31
  30. package/dist/{chunk-D2OTBS47.js → chunk-CSVJGW3I.js} +2 -2
  31. package/dist/{chunk-GANAOCHR.js → chunk-CXJC3JLN.js} +25 -374
  32. package/dist/{chunk-WAZJPDR2.js → chunk-D4VGJQY7.js} +1 -1
  33. package/dist/{chunk-BRUDBWLO.js → chunk-D5I5SSPU.js} +7 -7
  34. package/dist/{chunk-KFUDKFEH.js → chunk-D6EXW4EB.js} +45 -19
  35. package/dist/{chunk-AF6DQJ5W.js → chunk-DG3M5DZU.js} +1 -1
  36. package/dist/{chunk-WT7J2627.js → chunk-DTCTXDJP.js} +1 -1
  37. package/dist/chunk-DTQPDMHG.js +654 -0
  38. package/dist/{chunk-EZRAR5YG.js → chunk-E3TP4QTM.js} +1 -1
  39. package/dist/{chunk-NFZJ5XHP.js → chunk-ENBOAE2W.js} +33 -32
  40. package/dist/{chunk-R3252UTU.js → chunk-ENMX3VQ7.js} +7 -7
  41. package/dist/{chunk-AH6634HC.js → chunk-FOSYM7TQ.js} +1 -2
  42. package/dist/{chunk-HL7UNTXO.js → chunk-FRMAQ3C4.js} +17 -10
  43. package/dist/{chunk-HAWPG7QW.js → chunk-FTP7SE6Y.js} +3 -3
  44. package/dist/{chunk-IP7BIBXJ.js → chunk-FWSVWPMS.js} +16 -7
  45. package/dist/{chunk-GLUQVET2.js → chunk-GFZ7PELR.js} +6 -6
  46. package/dist/{chunk-UZGQT6OF.js → chunk-H2NJG3TE.js} +6 -3
  47. package/dist/{chunk-46OBCATR.js → chunk-HRHWA6TZ.js} +1 -1
  48. package/dist/chunk-HTRDL42C.js +45 -0
  49. package/dist/{chunk-YBAVN6WS.js → chunk-I4DM7SNX.js} +7 -7
  50. package/dist/{chunk-24FEVLX7.js → chunk-I6U6QPN6.js} +1311 -73
  51. package/dist/{chunk-4DJZSNVT.js → chunk-IKFAJTLZ.js} +1 -1
  52. package/dist/{chunk-55PYF6S2.js → chunk-J2OMKFYB.js} +3 -3
  53. package/dist/{chunk-7Y5VW4JG.js → chunk-K2G3VB7W.js} +1 -1
  54. package/dist/chunk-K7N6LAPC.js +78 -0
  55. package/dist/{chunk-ULBVE7MP.js → chunk-KRCU66AM.js} +9 -9
  56. package/dist/{chunk-JU3VU42K.js → chunk-LHHDX7FB.js} +5 -5
  57. package/dist/{chunk-FUJUFLDC.js → chunk-LO4CK734.js} +8 -14
  58. package/dist/chunk-LSLK4RS4.js +82 -0
  59. package/dist/{chunk-ABAVN4RT.js → chunk-LSZUTI6O.js} +29 -26
  60. package/dist/chunk-MVPOYQQY.js +136 -0
  61. package/dist/{chunk-YQHEJ5SV.js → chunk-NXQK2I3G.js} +3 -3
  62. package/dist/{chunk-DJMR4YPG.js → chunk-O3MJAHLI.js} +82 -96
  63. package/dist/{chunk-B7PYT2BY.js → chunk-PBGNX3PS.js} +6 -3
  64. package/dist/{chunk-CJJDJ7AT.js → chunk-PIZA7OG2.js} +5 -3
  65. package/dist/{chunk-RIHB3HA2.js → chunk-PMA67TIN.js} +3 -3
  66. package/dist/{chunk-DJDTL6AY.js → chunk-QKOJ22OV.js} +148 -293
  67. package/dist/{chunk-RDWKRG4K.js → chunk-RF4JHGGB.js} +7 -7
  68. package/dist/{chunk-MOOZJRKM.js → chunk-SJJXDU2J.js} +27 -30
  69. package/dist/chunk-T5QBWM6M.js +113 -0
  70. package/dist/{chunk-W7I65BKE.js → chunk-TJIFYV2Z.js} +12 -12
  71. package/dist/{chunk-EBOQU6QC.js → chunk-TKY3SDXH.js} +6 -6
  72. package/dist/{chunk-ALEUIS35.js → chunk-ULBYRPAP.js} +1 -1
  73. package/dist/{chunk-ZP7F3OHV.js → chunk-URHS76GV.js} +48 -38
  74. package/dist/{chunk-X2XTCGUS.js → chunk-VAYVTUU4.js} +11 -12
  75. package/dist/{chunk-TSYHUUAT.js → chunk-VUH7KKVD.js} +3 -3
  76. package/dist/{chunk-RIIPBJK6.js → chunk-WACPWYMH.js} +4 -4
  77. package/dist/{chunk-AAGU5FJF.js → chunk-WGC7UFRM.js} +1 -1
  78. package/dist/{chunk-2SRQSGPR.js → chunk-WVAXJOWG.js} +30 -24
  79. package/dist/{chunk-KLXECBIE.js → chunk-XEWG4AB2.js} +151 -108
  80. package/dist/{chunk-KDK6AF7B.js → chunk-XIDDJSQU.js} +7 -6
  81. package/dist/{chunk-MXIFRYLA.js → chunk-Y4E7IS7H.js} +2 -2
  82. package/dist/{chunk-DHFNBNC3.js → chunk-YJQ7YA7J.js} +5 -5
  83. package/dist/{chunk-6A2GEFN3.js → chunk-YMVRCSKD.js} +4 -4
  84. package/dist/{chunk-JW5BENE6.js → chunk-YYQ5NOT5.js} +3 -3
  85. package/dist/chunk-ZHQC43NH.js +130 -0
  86. package/dist/{chunk-KB5B6ZT5.js → chunk-ZSRMJOAK.js} +20 -20
  87. package/dist/{claude-launcher-L77BKZOC.js → claude-launcher-LGKJZH33.js} +99 -120
  88. package/dist/{cli-QQY5UECM.js → cli-Q5L64EEG.js} +327 -298
  89. package/dist/{cli-update-notice-T3CXRWNB.js → cli-update-notice-AWYJ4A7R.js} +2 -2
  90. package/dist/{command-QLHQZ32L.js → command-CGEFJZNC.js} +65 -64
  91. package/dist/{config-5GY7FL35.js → config-T22KVOOT.js} +14 -10
  92. package/dist/connect-cmd-RUBP466E.js +28 -0
  93. package/dist/{container-start-OCJODSMB.js → container-start-JRF3SBUA.js} +65 -62
  94. package/dist/{context-cleanup-A7KBEBIO.js → context-cleanup-3K2AOECJ.js} +6 -2
  95. package/dist/{context-show-cmd-MZ74ZIVO.js → context-show-cmd-4UXO5WQJ.js} +18 -16
  96. package/dist/{control-plane-launch-3TZFOSCX.js → control-plane-launch-AAH4YH56.js} +31 -27
  97. package/dist/{demo-record-cmd-Y57UWBCX.js → demo-record-cmd-2OKCGST7.js} +10 -5
  98. package/dist/{demo-voice-cmd-4INIOVTC.js → demo-voice-cmd-GEPX7GIG.js} +27 -27
  99. package/dist/{dist-6KGTCWKR.js → dist-VVZIGSAF.js} +1 -1
  100. package/dist/docker-5VWK335X.js +19 -0
  101. package/dist/{doctor-DB2AJUAO.js → doctor-EQM3JRZI.js} +81 -76
  102. package/dist/emit-artifact-cmd-TA3MPHLU.js +43 -0
  103. package/dist/{emit-cmd-IOWTTZSA.js → emit-cmd-RO4L4PFZ.js} +9 -8
  104. package/dist/emit-criteria-cmd-NMTUV2KM.js +34 -0
  105. package/dist/emit-demo-cmd-Y2Y6LEL7.js +46 -0
  106. package/dist/{emit-finding-cmd-KQIGM5IF.js → emit-finding-cmd-VECM64UR.js} +20 -19
  107. package/dist/{emit-result-cmd-6Q7OU2NY.js → emit-result-cmd-2ERWFDUN.js} +25 -24
  108. package/dist/{emit-step-cmd-GZU5O2FR.js → emit-step-cmd-V2ET66N4.js} +20 -19
  109. package/dist/exec-client-54XKNPTI.js +16 -0
  110. package/dist/find-unit-CNAPU7XQ.js +23 -0
  111. package/dist/{findings-cmd-T7PQAVJG.js → findings-cmd-QJPPF6BY.js} +20 -19
  112. package/dist/{fleet-readiness-PTMOEX6L.js → fleet-readiness-DKAPHAZN.js} +16 -15
  113. package/dist/governing-source-7PZ6DAJU.js +40 -0
  114. package/dist/guest-init-5QZRGP62.js +18 -0
  115. package/dist/{hook-fast-RW7RU3O6.js → hook-fast-VXROB4KF.js} +7 -5
  116. package/dist/hook-install-GDNRMML4.js +14 -0
  117. package/dist/{hook-wrap-fast-545QJSBJ.js → hook-wrap-fast-LWWKKPGK.js} +4 -2
  118. package/dist/host-checks-WAPO5X7X.js +78 -0
  119. package/dist/host-key-HLLV37NV.js +16 -0
  120. package/dist/image-tag-PBWQBATH.js +17 -0
  121. package/dist/index.js +8 -9
  122. package/dist/init-EK3PUU6W.js +78 -0
  123. package/dist/{init-HUQLVUPO.js → init-Y2URPVVY.js} +62 -59
  124. package/dist/{init-cmd-6NQGBVAJ.js → init-cmd-XNANUDIW.js} +38 -33
  125. package/dist/{init-update-MA6QKX46.js → init-update-EFCTKF6D.js} +55 -46
  126. package/dist/install-cmd-RHFUZFV4.js +19 -0
  127. package/dist/layout-7XMC7S6K.js +13 -0
  128. package/dist/{logs-FEITSC2V.js → logs-E7MGQINH.js} +10 -3
  129. package/dist/loop-L6TX6OR4.js +89 -0
  130. package/dist/machine-VJKAY2GX.js +78 -0
  131. package/dist/{machine-skills-237PQFRC.js → machine-skills-HR4RNRNR.js} +5 -4
  132. package/dist/{mcp-install-cmd-23ZY4IBK.js → mcp-install-cmd-SMPLT43Q.js} +7 -1
  133. package/dist/{mcp-serve-cmd-ZINYSLY6.js → mcp-serve-cmd-XXERT673.js} +11 -7
  134. package/dist/{paths-XEYE7OZ2.js → paths-F2ZR2EKC.js} +10 -3
  135. package/dist/pending-VOFQRXP4.js +16 -0
  136. package/dist/pidfile-7M7O2M7T.js +17 -0
  137. package/dist/record-YCJ6DZOY.js +16 -0
  138. package/dist/{relay-IEYNSKAZ.js → relay-I2T43PPB.js} +8 -1
  139. package/dist/relay-protocol-GI2GC2AM.js +13 -0
  140. package/dist/runner-env-YW55JVU7.js +23 -0
  141. package/dist/runner-identity-Y5ZFCC7V.js +19 -0
  142. package/dist/{runner-key-CFZ47PR3.js → runner-key-R47C6374.js} +54 -54
  143. package/dist/session-sender-UPACLRGG.js +43 -0
  144. package/dist/{shell-function-NRD4KVUK.js → shell-function-GYD2ZQQG.js} +2 -1
  145. package/dist/{spec-cmd-CNASSB6L.js → spec-cmd-7QRE2SZK.js} +21 -20
  146. package/dist/{starter-pack-CCVIEY72.js → starter-pack-IMKIUA56.js} +7 -6
  147. package/dist/state-VAHBIMS5.js +16 -0
  148. package/dist/{status-VNHIHQ57.js → status-BQEYEG2V.js} +54 -54
  149. package/dist/{statusline-fast-E7RWVREA.js → statusline-fast-NUVHCNRX.js} +4 -2
  150. package/dist/{sync-cmd-5JLJBODH.js → sync-cmd-NBLYEPQG.js} +25 -24
  151. package/dist/update-steps-VGKNGWTZ.js +79 -0
  152. package/dist/{watch-AEWWTUEK.js → watch-IHV4V3HZ.js} +25 -24
  153. package/dist/{work-claim-cmd-GUYOJYH7.js → work-claim-cmd-WGTSU5IT.js} +24 -24
  154. package/dist/{work-cmd-YRPYMGII.js → work-cmd-HKOJU5FJ.js} +18 -17
  155. package/dist/{work-comment-cmd-U5Z6FKEU.js → work-comment-cmd-H3JCWQ2J.js} +21 -20
  156. package/dist/{work-demo-cmd-OLCWTVWM.js → work-demo-cmd-J4AZAIVP.js} +18 -17
  157. package/dist/{work-launch-TTGSHLY4.js → work-launch-LWDQXLGI.js} +1 -1
  158. package/dist/{work-logs-cmd-2OA7ENDU.js → work-logs-cmd-UOO4JVLG.js} +18 -17
  159. package/dist/{work-open-pr-cmd-6GUCDYVM.js → work-open-pr-cmd-QFRDDBAM.js} +20 -19
  160. package/dist/{work-pr-cmd-KK3VQUQI.js → work-pr-cmd-3Q2D5RQT.js} +19 -18
  161. package/dist/{work-proofs-cmd-BUOS5OJC.js → work-proofs-cmd-7Y3HGT7C.js} +21 -20
  162. package/dist/{work-proofs-record-6WLMOK53.js → work-proofs-record-QPUM6DY4.js} +31 -31
  163. package/dist/{work-stop-cmd-VZJX5X4L.js → work-stop-cmd-SD2ZRMSY.js} +18 -17
  164. package/package.json +1 -1
  165. package/dist/agent-setup-DJRQFPDU.js +0 -33
  166. package/dist/bridge-XM4QLKIX.js +0 -8
  167. package/dist/build-ZE5IG3V6.js +0 -18
  168. package/dist/build-disk-GMXDIZU4.js +0 -15
  169. package/dist/builder-LJ3FSB36.js +0 -14
  170. package/dist/caller-YLNJJPFU.js +0 -18
  171. package/dist/chunk-CXFJOX2C.js +0 -144
  172. package/dist/chunk-FGF52V4V.js +0 -137
  173. package/dist/chunk-HCVLP7XA.js +0 -53
  174. package/dist/chunk-KYDEBGJG.js +0 -402
  175. package/dist/chunk-MESOOLF4.js +0 -45
  176. package/dist/chunk-OHQMGLJP.js +0 -113
  177. package/dist/chunk-OUPQTA7N.js +0 -145
  178. package/dist/chunk-VRMXYQWR.js +0 -74
  179. package/dist/connect-cmd-THV7XBVP.js +0 -27
  180. package/dist/docker-5YVUZ3J2.js +0 -14
  181. package/dist/emit-artifact-cmd-H27MFSKH.js +0 -42
  182. package/dist/emit-criteria-cmd-IOUVMB2Q.js +0 -33
  183. package/dist/emit-demo-cmd-WJSS7KU2.js +0 -46
  184. package/dist/exec-client-FGGPQSYQ.js +0 -9
  185. package/dist/find-unit-PRZIFBIK.js +0 -19
  186. package/dist/governing-source-CND5ZZC3.js +0 -39
  187. package/dist/guest-init-WPUS45IN.js +0 -11
  188. package/dist/host-checks-S3B7Z4SY.js +0 -78
  189. package/dist/host-key-O4DFMOSV.js +0 -9
  190. package/dist/image-tag-WBD57QBN.js +0 -10
  191. package/dist/init-ILTX4V56.js +0 -78
  192. package/dist/install-cmd-JKPXIOEY.js +0 -12
  193. package/dist/layout-2ZMCT2D3.js +0 -11
  194. package/dist/loop-KDWDOSMQ.js +0 -89
  195. package/dist/machine-Z6K5XXI6.js +0 -78
  196. package/dist/pending-D2NNV54J.js +0 -9
  197. package/dist/pidfile-FLFVRKVW.js +0 -10
  198. package/dist/record-JMZOXD4R.js +0 -9
  199. package/dist/relay-protocol-5LSWUJCW.js +0 -6
  200. package/dist/runner-env-W2UMHY7P.js +0 -19
  201. package/dist/runner-identity-IIY5UJL3.js +0 -14
  202. package/dist/session-sender-NO4F2IQ5.js +0 -42
  203. package/dist/settings-XB2HYBKO.js +0 -7
  204. package/dist/state-UWIM42JH.js +0 -9
  205. package/dist/update-steps-XGOXDCOS.js +0 -79
  206. package/dist/{chunk-OLM2TIOW.js → chunk-NFZMENCY.js} +1 -1
@@ -1,47 +1,50 @@
1
1
  #!/usr/bin/env node
2
2
  import { createRequire } from 'node:module';
3
- import { gatherDoctorChecks, doctorExitCode, summarizeChecks, renderDoctorText, recordWrapped, recordUnwrapped, recordRemoval, readManifest, recordInstall, recordStatusline } from './chunk-DJDTL6AY.js';
4
- import './chunk-JU3VU42K.js';
5
- import './chunk-OHQMGLJP.js';
6
- import './chunk-B62TYDP2.js';
7
- import { verifiedTrackerNames, TRACKERS } from './chunk-SPXVFFQV.js';
8
- import './chunk-IP7BIBXJ.js';
9
- import './chunk-TSYHUUAT.js';
10
- import './chunk-HL7UNTXO.js';
3
+ import { gatherDoctorChecks, doctorExitCode, summarizeChecks, renderDoctorText, recordWrapped, recordUnwrapped, recordRemoval, readManifest, recordInstall, recordStatusline } from './chunk-QKOJ22OV.js';
4
+ import './chunk-LHHDX7FB.js';
5
+ import './chunk-SJJXDU2J.js';
6
+ import './chunk-MVPOYQQY.js';
7
+ import './chunk-B5SWBFVE.js';
8
+ import { verifiedTrackerNames, TRACKERS } from './chunk-AQE6E54X.js';
9
+ import './chunk-FWSVWPMS.js';
10
+ import './chunk-VUH7KKVD.js';
11
+ import './chunk-FRMAQ3C4.js';
12
+ import './chunk-P6PHY33P.js';
13
+ import './chunk-6KH3NMIT.js';
14
+ import { FIRST_VERSION_READING_AGENTS_SKILLS } from './chunk-D6EXW4EB.js';
11
15
  import './chunk-TPMLB3VZ.js';
12
16
  import './chunk-A2LHHKTT.js';
13
17
  import { C, warnDeprecated, API_KEY_FLAG_DEPRECATION, NO_COLOR_FLAG, stripNoColor } from './chunk-2AM6Z5BP.js';
14
- import './chunk-MOOZJRKM.js';
15
- import './chunk-P6PHY33P.js';
16
- import { FIRST_VERSION_READING_AGENTS_SKILLS } from './chunk-KFUDKFEH.js';
17
- import './chunk-LEHBDEUG.js';
18
- import './chunk-YQHEJ5SV.js';
18
+ import './chunk-B36NSEUM.js';
19
+ import './chunk-NXQK2I3G.js';
19
20
  import './chunk-HWVMRETT.js';
20
- import './chunk-4DJZSNVT.js';
21
- import { hookFiredMarkerPath, installedCliDistDir } from './chunk-DJMR4YPG.js';
21
+ import './chunk-IKFAJTLZ.js';
22
+ import { hookFiredMarkerPath, installedCliDistDir } from './chunk-O3MJAHLI.js';
22
23
  import './chunk-545P7JY7.js';
23
- import './chunk-YBAVN6WS.js';
24
+ import './chunk-I4DM7SNX.js';
24
25
  import './chunk-BKO6JEZI.js';
25
- import './chunk-HCVLP7XA.js';
26
+ import './chunk-4DLJ343I.js';
27
+ import './chunk-BSPJI5T7.js';
26
28
  import { findGitDirs } from './chunk-BJ3KTMDH.js';
27
- import './chunk-ABAVN4RT.js';
28
- import './chunk-CXFJOX2C.js';
29
- import './chunk-5GHJFETA.js';
30
- import './chunk-OLM2TIOW.js';
31
- import './chunk-CDDED64E.js';
32
- import { resolveVersion, resolvePackageVersion } from './chunk-RA3O54FC.js';
29
+ import './chunk-LSZUTI6O.js';
30
+ import './chunk-NFZMENCY.js';
33
31
  import { parseTrackerNumber, trackerNumberError } from './chunk-WZBHBH3J.js';
34
32
  import { cliInvocation, packageRunnerOf } from './chunk-FZKNTIOJ.js';
35
- import { settingsPath, readSettings, SettingsParseError, listHookCandidates, PORTABLE_BIN, wrapHooks, writeSettings, unwrapHooks, REGISTERED_EVENTS, removeHooks, removeStatusline, cliBinResolvable, mergeHooks, repointWrappedHooks, AUTO_WRAP_EVENTS, mergeStatusline } from './chunk-KYDEBGJG.js';
36
- import './chunk-B7PYT2BY.js';
33
+ import { installAgents, settingsFileOf, withSettingsText } from './chunk-HTRDL42C.js';
34
+ import { cliForInstall, SettingsParseError, PORTABLE_BIN, writeSettingsText, cliBinResolvable } from './chunk-ZHQC43NH.js';
35
+ import './chunk-PBGNX3PS.js';
37
36
  import { cloneIsGoverned } from './chunk-YQR6E6OV.js';
38
37
  import { removeJournalHooks, removePreCommitGuardHook } from './chunk-CJPTUU2E.js';
39
- import './chunk-24FEVLX7.js';
38
+ import './chunk-DTCTXDJP.js';
39
+ import './chunk-CXJC3JLN.js';
40
+ import './chunk-DTQPDMHG.js';
41
+ import { defaultAgents, legacyAgent } from './chunk-I6U6QPN6.js';
40
42
  import './chunk-WUKLQWGY.js';
43
+ import './chunk-T5QBWM6M.js';
44
+ import './chunk-LSLK4RS4.js';
45
+ import './chunk-CDDED64E.js';
46
+ import { resolveVersion, resolvePackageVersion } from './chunk-RA3O54FC.js';
41
47
  import { homeFromEnv } from './chunk-352DHUTP.js';
42
- import './chunk-WT7J2627.js';
43
- import './chunk-GANAOCHR.js';
44
- import './chunk-MESOOLF4.js';
45
48
  import './chunk-Z5GEFMRW.js';
46
49
  import { EventEmitter } from 'events';
47
50
  import childProcess, { execFileSync } from 'child_process';
@@ -3486,21 +3489,34 @@ function installCliCopy(opts) {
3486
3489
  }
3487
3490
  function runInit(opts) {
3488
3491
  const scope = opts.scope ?? "user";
3489
- const path2 = settingsPath(scope, { home: opts.home, cwd: opts.cwd });
3490
- const current = readSettings(path2);
3492
+ const list = opts.agents ?? defaultAgents();
3493
+ const [first, ...rest] = installAgents(list);
3494
+ if (first === void 0 || first.entry.descriptor.id !== legacyAgent(list).descriptor.id) throw new Error("the legacy agent has no hook settings");
3495
+ const where = { home: opts.home ?? homeFromEnv(), cwd: opts.cwd ?? process.cwd() };
3496
+ const path2 = first.install.settingsFile(scope, where);
3497
+ const cli = cliForInstall(opts.cliBin);
3491
3498
  const manifestHome = opts.home ?? homeFromEnv();
3492
3499
  if (opts.remove) {
3493
- const hooksRemoved = removeHooks(current, opts.cliBin);
3494
- const hooksUnwrapped = unwrapHooks(hooksRemoved.next, opts.cliBin);
3495
- const statuslineRemoved = removeStatusline(hooksUnwrapped.next, opts.cliBin);
3496
- const changed2 = hooksRemoved.changed || hooksUnwrapped.changed || statuslineRemoved.changed;
3497
- const backupPath2 = changed2 ? writeSettings(path2, statuslineRemoved.next) : void 0;
3500
+ const result = withSettingsText(path2, (text) => first.install.remove(text, cli));
3501
+ const otherResults = rest.map((agent) => {
3502
+ const file = agent.install.settingsFile(scope, where);
3503
+ return { agent, file, result: withSettingsText(file, (text) => agent.install.remove(text, cli)) };
3504
+ });
3505
+ const backupPath2 = result.changed ? writeSettingsText(path2, result.text) : void 0;
3506
+ const others2 = otherResults.map(({ agent, file, result: removed }) => ({
3507
+ agent: agent.entry.descriptor.id,
3508
+ path: file,
3509
+ changed: removed.changed,
3510
+ backupPath: removed.changed ? writeSettingsText(file, removed.text) : void 0,
3511
+ events: agent.events,
3512
+ removed: true
3513
+ }));
3498
3514
  const gitHookRemoval2 = removeJournalHooks(opts.cwd ?? process.cwd());
3499
3515
  const guardHookRemoval = removePreCommitGuardHook(opts.cwd ?? process.cwd());
3500
- recordRemoval(manifestHome, path2);
3516
+ for (const file of [path2, ...others2.map((other) => other.path)]) recordRemoval(manifestHome, file);
3501
3517
  const remaining = readManifest(manifestHome);
3502
3518
  if (!remaining || Object.keys(remaining.installs).length === 0) {
3503
- for (const event of REGISTERED_EVENTS) {
3519
+ for (const event of new Set([first, ...rest].flatMap((agent) => agent.events))) {
3504
3520
  try {
3505
3521
  unlinkSync(hookFiredMarkerPath(event, manifestHome));
3506
3522
  } catch {
@@ -3509,49 +3525,30 @@ function runInit(opts) {
3509
3525
  }
3510
3526
  return {
3511
3527
  path: path2,
3512
- changed: changed2,
3528
+ changed: result.changed,
3513
3529
  backupPath: backupPath2,
3514
- events: REGISTERED_EVENTS,
3530
+ events: first.events,
3515
3531
  removed: true,
3516
3532
  gitHookRemoved: gitHookRemoval2.removed,
3517
3533
  guardHookRemoved: guardHookRemoval.removed,
3518
3534
  wrapped: [],
3519
- unwrappedCount: hooksUnwrapped.unwrapped,
3520
- ...statuslineRemoved.restoredCommand ? { statuslineWrappedCommand: statuslineRemoved.restoredCommand } : {}
3535
+ unwrappedCount: result.unwrapped,
3536
+ ...result.restoredStatusline ? { statuslineWrappedCommand: result.restoredStatusline } : {},
3537
+ ...others2.length > 0 ? { others: others2 } : {}
3521
3538
  };
3522
3539
  }
3540
+ const options = { wrap: opts.wrapHooks ?? true, statusline: opts.statusline ?? true };
3541
+ const installed = withSettingsText(path2, (text) => first.install.install(text, cli, options));
3523
3542
  if (!cliBinResolvable(opts.cliBin)) {
3524
- return { path: path2, changed: false, events: REGISTERED_EVENTS, wrapped: [], cliBinUnresolved: true };
3525
- }
3526
- const merged = mergeHooks(current, opts.cliBin);
3527
- const repointed = repointWrappedHooks(merged.next, opts.cliBin);
3528
- let next = repointed.next;
3529
- let changed = merged.changed || repointed.changed;
3530
- let wrapped = [];
3531
- if (opts.wrapHooks ?? true) {
3532
- const wrapResult = wrapHooks(next, opts.cliBin, { events: [...AUTO_WRAP_EVENTS] });
3533
- if (wrapResult.changed) {
3534
- next = wrapResult.next;
3535
- changed = true;
3536
- wrapped = wrapResult.wrapped;
3537
- }
3538
- }
3539
- let statusline;
3540
- let statuslineWrappedCommand;
3541
- if (opts.statusline ?? true) {
3542
- const slotResult = mergeStatusline(next, opts.cliBin);
3543
- statusline = slotResult.outcome;
3544
- statuslineWrappedCommand = slotResult.wrappedCommand;
3545
- if (slotResult.changed) {
3546
- next = slotResult.next;
3547
- changed = true;
3548
- }
3549
- }
3550
- const backupPath = changed ? writeSettings(path2, next) : void 0;
3551
- recordInstall(manifestHome, path2, { cliBin: opts.cliBin, events: REGISTERED_EVENTS });
3552
- recordWrapped(manifestHome, path2, wrapped.map((c) => ({ event: c.event, original: c.command })));
3543
+ return { path: path2, changed: false, events: first.events, wrapped: [], cliBinUnresolved: true };
3544
+ }
3545
+ const others = rest.map((agent) => installOther(agent, scope, where, cli, options, opts.cliBin, manifestHome));
3546
+ const backupPath = installed.changed ? writeSettingsText(path2, installed.text) : void 0;
3547
+ recordInstall(manifestHome, path2, { cliBin: opts.cliBin, events: [...first.events] });
3548
+ recordWrapped(manifestHome, path2, installed.wrapped.map((c) => ({ event: c.event, original: c.command })));
3549
+ const statusline = installed.statusline;
3553
3550
  if (statusline && statusline !== "skipped") {
3554
- recordStatusline(manifestHome, path2, statuslineWrappedCommand !== void 0 ? "wrapped" : "installed", statuslineWrappedCommand);
3551
+ recordStatusline(manifestHome, path2, installed.statuslineWrappedCommand !== void 0 ? "wrapped" : "installed", installed.statuslineWrappedCommand);
3555
3552
  }
3556
3553
  const gitHookRemoval = removeJournalHooks(opts.cwd ?? process.cwd());
3557
3554
  let gitignoreUpdated = false;
@@ -3560,16 +3557,25 @@ function runInit(opts) {
3560
3557
  }
3561
3558
  return {
3562
3559
  path: path2,
3563
- changed,
3560
+ changed: installed.changed,
3564
3561
  backupPath,
3565
- events: REGISTERED_EVENTS,
3562
+ events: first.events,
3566
3563
  gitignoreUpdated,
3567
3564
  ...gitHookRemoval.removed ? { gitHookRemoved: true } : {},
3568
- wrapped,
3565
+ wrapped: installed.wrapped,
3569
3566
  ...statusline ? { statusline } : {},
3570
- ...statuslineWrappedCommand ? { statuslineWrappedCommand } : {}
3567
+ ...installed.statuslineWrappedCommand ? { statuslineWrappedCommand: installed.statuslineWrappedCommand } : {},
3568
+ ...others.length > 0 ? { others } : {}
3571
3569
  };
3572
3570
  }
3571
+ function installOther(agent, scope, where, cli, options, cliBin, manifestHome) {
3572
+ const file = agent.install.settingsFile(scope, where);
3573
+ const installed = withSettingsText(file, (text) => agent.install.install(text, cli, options));
3574
+ const backupPath = installed.changed ? writeSettingsText(file, installed.text) : void 0;
3575
+ recordInstall(manifestHome, file, { cliBin, events: [...agent.events] });
3576
+ recordWrapped(manifestHome, file, installed.wrapped.map((c) => ({ event: c.event, original: c.command })));
3577
+ return { agent: agent.entry.descriptor.id, path: file, changed: installed.changed, backupPath, events: agent.events };
3578
+ }
3573
3579
  function tracksOwnOuterlayerDir(cwd) {
3574
3580
  try {
3575
3581
  const out = execFileSync("git", ["-C", cwd, "ls-files", "--", ".outerlayer"], {
@@ -3602,22 +3608,16 @@ function ensureGitignore(cwd) {
3602
3608
  `);
3603
3609
  return true;
3604
3610
  }
3605
- function orgRolloutSnippet() {
3606
- const hooks = {};
3607
- for (const event of REGISTERED_EVENTS) {
3608
- hooks[event] = [{ hooks: [{ type: "command", command: `${PORTABLE_BIN} hook ${event}` }] }];
3609
- }
3610
- const managed = JSON.stringify({ hooks }, null, 2);
3611
+ function orgRolloutSnippet(agents = defaultAgents()) {
3612
+ const { install } = installAgents(agents)[0];
3613
+ const managed = JSON.stringify(install.managedSettings.document((event) => `${PORTABLE_BIN} hook ${event}`), null, 2);
3611
3614
  return [
3612
3615
  "# Org-wide rollout (managed settings)",
3613
3616
  "",
3614
3617
  "Deploy this managed-settings.json to every developer machine via MDM/GPO.",
3615
3618
  "It cannot be overridden by users, guaranteeing fleet-wide capture.",
3616
3619
  "",
3617
- " macOS (MDM): /Library/Application Support/ClaudeCode/managed-settings.json",
3618
- " (domain com.anthropic.claudecode)",
3619
- " Linux: /etc/claude-code/managed-settings.json",
3620
- " Windows (GPO): HKLM\\SOFTWARE\\Policies\\ClaudeCode, as a REG_SZ value named Settings",
3620
+ ...install.managedSettings.locations,
3621
3621
  "",
3622
3622
  "managed-settings.json:",
3623
3623
  managed,
@@ -3658,14 +3658,14 @@ function apiKeyOption() {
3658
3658
  return new Option("--api-key <key>", `deprecated: use \`${cliInvocation()} login\` or OUTERLAYER_API_KEY`).hideHelp();
3659
3659
  }
3660
3660
  async function installStarterPackInRepo() {
3661
- const { installStarterPack, formatStarterPackOutput } = await import('./starter-pack-CCVIEY72.js');
3661
+ const { installStarterPack, formatStarterPackOutput } = await import('./starter-pack-IMKIUA56.js');
3662
3662
  const cwd = process.cwd();
3663
3663
  let repoRoot = cwd;
3664
3664
  try {
3665
3665
  repoRoot = execFileSync("git", ["rev-parse", "--show-toplevel"], { cwd, encoding: "utf8", stdio: ["ignore", "pipe", "ignore"] }).trim() || cwd;
3666
3666
  } catch {
3667
3667
  }
3668
- const { declareAgentsMdLayout, isAgentsMdLayout, skillsBaseFor } = await import('./layout-2ZMCT2D3.js');
3668
+ const { declareAgentsMdLayout, isAgentsMdLayout, skillsBaseFor } = await import('./layout-7XMC7S6K.js');
3669
3669
  const fresh = !isAgentsMdLayout(repoRoot) && !existsSync(join(repoRoot, ".outerlayer/skills")) && !existsSync(join(repoRoot, ".outerlayer/AGENTS.md"));
3670
3670
  const result = installStarterPack({ repoRoot, base: fresh ? ".agents/skills" : skillsBaseFor(repoRoot) });
3671
3671
  if (fresh) declareAgentsMdLayout(repoRoot);
@@ -3688,6 +3688,14 @@ ${C.dim} backup: ${result.backupPath}${C.reset}` : ""}
3688
3688
  lines.push(`${C.green}\u2713${C.reset} Restored status line to: ${C.dim}${result.statuslineWrappedCommand}${C.reset}
3689
3689
  `);
3690
3690
  }
3691
+ for (const other of result.others ?? []) {
3692
+ lines.push(
3693
+ other.changed ? `${C.green}\u2713${C.reset} Removed OuterLayer hooks from ${other.path}${other.backupPath ? `
3694
+ ${C.dim} backup: ${other.backupPath}${C.reset}` : ""}
3695
+ ` : `${C.dim}No OuterLayer hooks to remove in ${other.path}${C.reset}
3696
+ `
3697
+ );
3698
+ }
3691
3699
  return lines.join("");
3692
3700
  }
3693
3701
  if (!result.changed) {
@@ -3700,6 +3708,14 @@ ${C.dim} backup: ${result.backupPath}${C.reset}` : ""}
3700
3708
  ` : "")
3701
3709
  );
3702
3710
  }
3711
+ for (const other of result.others ?? []) {
3712
+ lines.push(
3713
+ other.changed ? `${C.green}\u2713${C.reset} Installed ${other.events.join(", ")} hooks \u2192 ${other.path}
3714
+ ` + (other.backupPath ? `${C.dim} backup: ${other.backupPath}${C.reset}
3715
+ ` : "") : `${C.green}\u2713${C.reset} Hooks already installed in ${other.path} (no change)
3716
+ `
3717
+ );
3718
+ }
3703
3719
  if (result.wrapped.length > 0) {
3704
3720
  lines.push(
3705
3721
  `${C.green}\u2713${C.reset} Auto-wrapped ${result.wrapped.length} hook(s) for execution evidence (adds one spawn per firing \u2014 see ${C.yellow}${cliInvocation()} hooks unwrap${C.reset} to undo):
@@ -3791,7 +3807,7 @@ ${starter.output}`),
3791
3807
  }
3792
3808
  }
3793
3809
  async function installMachineSkillsForSetup() {
3794
- const { setupMachineSkills } = await import('./machine-skills-237PQFRC.js');
3810
+ const { setupMachineSkills } = await import('./machine-skills-HR4RNRNR.js');
3795
3811
  const result = setupMachineSkills(homeFromEnv());
3796
3812
  for (const failure of result.failures) process.stderr.write(`${C.yellow}!${C.reset} Could not write a maintained skill: ${failure}
3797
3813
  `);
@@ -3799,8 +3815,8 @@ async function installMachineSkillsForSetup() {
3799
3815
  ` : "";
3800
3816
  }
3801
3817
  async function realConnectDepsForCwd() {
3802
- const { realConnectDeps } = await import('./connect-cmd-THV7XBVP.js');
3803
- const { resolveRepoIdentity } = await import('./dist-6KGTCWKR.js');
3818
+ const { realConnectDeps } = await import('./connect-cmd-RUBP466E.js');
3819
+ const { resolveRepoIdentity } = await import('./dist-VVZIGSAF.js');
3804
3820
  return {
3805
3821
  ...realConnectDeps(),
3806
3822
  home: homeFromEnv(),
@@ -3817,12 +3833,12 @@ function buildProgram(argv = process.argv) {
3817
3833
  const program2 = new Command();
3818
3834
  program2.name(cliInvocation()).description("OuterLayer \u2014 see what your coding agents actually do").enablePositionalOptions().version(resolveVersion()).hook("preAction", async (_root, command) => {
3819
3835
  if (command.opts().apiKey !== void 0) warnDeprecated(API_KEY_FLAG_DEPRECATION);
3820
- const { machineRefreshSkipped, refreshMachineSkills } = await import('./machine-skills-237PQFRC.js');
3836
+ const { machineRefreshSkipped, refreshMachineSkills } = await import('./machine-skills-HR4RNRNR.js');
3821
3837
  const names = [];
3822
3838
  for (let at = command; at?.parent; at = at.parent) names.push(at.name());
3823
3839
  if (!machineRefreshSkipped(names, command._hidden === true, argv)) refreshMachineSkills(homeFromEnv());
3824
3840
  }).hook("postAction", async (_root, command) => {
3825
- const notice = await import('./cli-update-notice-T3CXRWNB.js');
3841
+ const notice = await import('./cli-update-notice-AWYJ4A7R.js');
3826
3842
  let top;
3827
3843
  for (let at = command; at.parent; at = at.parent) top = at.name();
3828
3844
  const json = command.opts().json === true || argv.includes("--json");
@@ -3874,8 +3890,8 @@ build, ../outerlayer-build/SKILL.md becomes ~/.agents/skills/outerlayer-build/SK
3874
3890
  what CLIs older than ${FIRST_VERSION_READING_AGENTS_SKILLS} do. \`` + cliInvocation() + " doctor` reports the same\nstates under Starter files.\n"
3875
3891
  ).action(async (opts) => {
3876
3892
  if (opts.update || opts.dryRun) {
3877
- const { runInitUpdateWithFleet, formatInitUpdate, updateFlagProblem } = await import('./init-update-MA6QKX46.js');
3878
- const { fleetReadiness } = await import('./fleet-readiness-PTMOEX6L.js');
3893
+ const { runInitUpdateWithFleet, formatInitUpdate, updateFlagProblem } = await import('./init-update-EFCTKF6D.js');
3894
+ const { fleetReadiness } = await import('./fleet-readiness-DKAPHAZN.js');
3879
3895
  const problem = updateFlagProblem(opts);
3880
3896
  if (problem !== void 0) {
3881
3897
  fail(problem);
@@ -3892,7 +3908,7 @@ what CLIs older than ${FIRST_VERSION_READING_AGENTS_SKILLS} do. \`` + cliInvocat
3892
3908
  }
3893
3909
  let starterTemplate;
3894
3910
  if (opts.template !== void 0) {
3895
- const { assertKnownTemplate, StarterPackError } = await import('./starter-pack-CCVIEY72.js');
3911
+ const { assertKnownTemplate, StarterPackError } = await import('./starter-pack-IMKIUA56.js');
3896
3912
  try {
3897
3913
  assertKnownTemplate(opts.template);
3898
3914
  } catch (err) {
@@ -3921,18 +3937,18 @@ what CLIs older than ${FIRST_VERSION_READING_AGENTS_SKILLS} do. \`` + cliInvocat
3921
3937
  return;
3922
3938
  }
3923
3939
  if (opts.remove) {
3924
- const { removeShellFunction } = await import('./shell-function-NRD4KVUK.js');
3940
+ const { removeShellFunction } = await import('./shell-function-GYD2ZQQG.js');
3925
3941
  const changed = removeShellFunction({ home: homeFromEnv() });
3926
3942
  if (changed.length > 0 && !opts.json) process.stdout.write(`Removed the claude function from ${changed.join(", ")}.
3927
3943
  `);
3928
3944
  }
3929
- const shell = !opts.remove && opts.shellFunction !== void 0 ? (await import('./init-cmd-6NQGBVAJ.js')).applyShellFunctionFlag(opts.shellFunction, { home: homeFromEnv(), shellPath: process.env.SHELL }) : void 0;
3945
+ const shell = !opts.remove && opts.shellFunction !== void 0 ? (await import('./init-cmd-XNANUDIW.js')).applyShellFunctionFlag(opts.shellFunction, { home: homeFromEnv(), shellPath: process.env.SHELL }) : void 0;
3930
3946
  if (opts.json) writeJson(shell === void 0 ? outcome.result : { ...outcome.result, shellFunction: { outcome: shell.outcome, reason: shell.reason } });
3931
3947
  else process.stdout.write(outcome.text + skillsLine + (shell?.text ?? ""));
3932
3948
  return;
3933
3949
  }
3934
3950
  await installMachineSkillsForSetup();
3935
- const { runInitCommand } = await import('./init-cmd-6NQGBVAJ.js');
3951
+ const { runInitCommand } = await import('./init-cmd-XNANUDIW.js');
3936
3952
  const code = await runInitCommand(
3937
3953
  { json: opts.json, factory: opts.factory, shellFunction: opts.shellFunction },
3938
3954
  {
@@ -3944,7 +3960,7 @@ what CLIs older than ${FIRST_VERSION_READING_AGENTS_SKILLS} do. \`` + cliInvocat
3944
3960
  return { ok, text, detail };
3945
3961
  },
3946
3962
  runAgentSetup: async () => {
3947
- const { runAgentSetup } = await import('./agent-setup-DJRQFPDU.js');
3963
+ const { runAgentSetup } = await import('./agent-setup-Q3HDN23U.js');
3948
3964
  return runAgentSetup({ cwd: process.cwd(), skillsLink: opts.skillsLink !== false });
3949
3965
  },
3950
3966
  runDoctorChecks: gatherDoctorChecks,
@@ -3953,7 +3969,7 @@ what CLIs older than ${FIRST_VERSION_READING_AGENTS_SKILLS} do. \`` + cliInvocat
3953
3969
  shellPath: process.env.SHELL,
3954
3970
  interactive: Boolean(process.stdin.isTTY && process.stderr.isTTY) && opts.json !== true,
3955
3971
  ask: async () => {
3956
- const { promptOnTerminal } = await import('./connect-cmd-THV7XBVP.js');
3972
+ const { promptOnTerminal } = await import('./connect-cmd-RUBP466E.js');
3957
3973
  const answer = await promptOnTerminal({
3958
3974
  message: `Should plain claude start Claude Code through ${cliInvocation()} claude? That is how a session in a governed repository gets its control plane. It adds one block to your zsh or bash startup file.`,
3959
3975
  options: [
@@ -3992,7 +4008,7 @@ linked (true, false, or null when it could not be checked) and, when false,
3992
4008
  linkUrl.
3993
4009
  `
3994
4010
  ).action(async (opts) => {
3995
- const { runConnectCommand } = await import('./connect-cmd-THV7XBVP.js');
4011
+ const { runConnectCommand } = await import('./connect-cmd-RUBP466E.js');
3996
4012
  const code = await runConnectCommand({ factory: opts.factory, json: opts.json }, await realConnectDepsForCwd(), {
3997
4013
  stdout: process.stdout,
3998
4014
  stderr: process.stderr
@@ -4070,7 +4086,7 @@ code is 1: revoke the token on /profile/security.
4070
4086
  else fail(found.reason);
4071
4087
  return;
4072
4088
  }
4073
- const { runSync, SyncConfigError, SyncTransportError } = await import('./sync-cmd-5JLJBODH.js');
4089
+ const { runSync, SyncConfigError, SyncTransportError } = await import('./sync-cmd-NBLYEPQG.js');
4074
4090
  try {
4075
4091
  const result = await runSync({
4076
4092
  url: opts.url,
@@ -4099,7 +4115,7 @@ code is 1: revoke the token on /profile/security.
4099
4115
  if (invokedCommandToken(argv) === "watch") {
4100
4116
  warnDeprecated(`\`${cliInvocation()} watch\` is now \`${cliInvocation()} daemon\`; the old name will be removed in a future release.`);
4101
4117
  }
4102
- const { runWatch } = await import('./watch-AEWWTUEK.js');
4118
+ const { runWatch } = await import('./watch-IHV4V3HZ.js');
4103
4119
  await runWatch({ once: opts.once });
4104
4120
  });
4105
4121
  program2.command("hook <event>", { hidden: true }).description("capture-hook fast path, installed by `init`").action(() => {
@@ -4108,11 +4124,14 @@ code is 1: revoke the token on /profile/security.
4108
4124
  });
4109
4125
  program2.command("hook-wrap", { hidden: true }).description("runs a hook wrapped by `hooks wrap`, recording exec evidence").option("--id <base64>", "the original hook command, base64-encoded").option("--capture-output", "tee stdout/stderr into a bounded tail").action(() => {
4110
4126
  });
4111
- program2.command("claude [args...]").description("start Claude Code with the repository's control plane attached").allowUnknownOption().helpOption(false).action(() => {
4112
- });
4127
+ for (const agent of defaultAgents()) {
4128
+ if (agent.adapter.launch === void 0) continue;
4129
+ program2.command(`${agent.descriptor.legacy?.subcommand ?? agent.descriptor.id} [args...]`).description(`start ${agent.descriptor.label} with the repository's control plane attached`).allowUnknownOption().helpOption(false).action(() => {
4130
+ });
4131
+ }
4113
4132
  const brokerRelay = program2.command("broker-relay", { hidden: true }).description("relay a build's loopback connections to the runner's tunnel and destinations").enablePositionalOptions().option("--port <port>", "the loopback port to listen on").option("--socket <path>", "the runner's tunnel socket").option("--join <path>", "the socket the runner's joining process connects to").option("--lease-watchdog", "exit when the runner's lease expiry passes; needs --join").option("--forward <port=target>", "also relay a loopback port to a destination; repeatable", (value, previous) => [...previous, value], []).action(async (opts) => {
4114
- const { startRelay, startSessionRelay } = await import('./relay-IEYNSKAZ.js');
4115
- const { TARGET_TUNNEL, targetOfPath } = await import('./relay-protocol-5LSWUJCW.js');
4133
+ const { startRelay, startSessionRelay } = await import('./relay-I2T43PPB.js');
4134
+ const { TARGET_TUNNEL, targetOfPath } = await import('./relay-protocol-GI2GC2AM.js');
4116
4135
  const port = Number(opts.port);
4117
4136
  if (!Number.isInteger(port) || port < 1 || port > 65535) {
4118
4137
  fail(opts.port === void 0 ? "--port is required" : `--port must be a port number, not ${opts.port}`);
@@ -4144,7 +4163,7 @@ code is 1: revoke the token on /profile/security.
4144
4163
  await startRelay({ port, socketPath: opts.socket, forwards: forwards.map((forward) => ({ port: forward.port, socketPath: forward.spec })) });
4145
4164
  });
4146
4165
  brokerRelay.command("join").description("carry the runner's session to the relay over standard input and output").option("--socket <path>", "the relay's joining socket", "/run/outerlayer-relay/join.sock").action(async (opts) => {
4147
- const { joinRelay } = await import('./relay-IEYNSKAZ.js');
4166
+ const { joinRelay } = await import('./relay-I2T43PPB.js');
4148
4167
  try {
4149
4168
  await joinRelay({ socketPath: opts.socket, input: process.stdin, output: process.stdout });
4150
4169
  } catch (err) {
@@ -4160,7 +4179,7 @@ code is 1: revoke the token on /profile/security.
4160
4179
  }
4161
4180
  });
4162
4181
  program2.command("vm-exec", { hidden: true }).description("run a command in a microVM build's guest through its exec agent").requiredOption("--socket <path>", "the Unix socket Firecracker serves the build's vsock device on").option("--user <user>", "the user to run as", "").option("--cwd <dir>", "the working directory", "/").option("--env <NAME=value>", "an environment value the command line carries; repeatable", (value, previous) => [...previous, value], []).option("--pass <NAME>", "an environment variable whose value is read from this process; repeatable", (value, previous) => [...previous, value], []).argument("<argv...>", "the command and its arguments").action(async (argv2, opts) => {
4163
- const { runVmExec } = await import('./exec-client-FGGPQSYQ.js');
4182
+ const { runVmExec } = await import('./exec-client-54XKNPTI.js');
4164
4183
  const env = {};
4165
4184
  for (const entry of opts.env) {
4166
4185
  const eq = entry.indexOf("=");
@@ -4189,7 +4208,7 @@ code is 1: revoke the token on /profile/security.
4189
4208
  process.exitCode = await runBuildCommand({ dir: opts.dir, argv: command });
4190
4209
  });
4191
4210
  program2.command("session-sender", { hidden: true }).description("stream a runner build's sessions to its work item while the build runs").action(async () => {
4192
- const { runSessionSender } = await import('./session-sender-NO4F2IQ5.js');
4211
+ const { runSessionSender } = await import('./session-sender-UPACLRGG.js');
4193
4212
  try {
4194
4213
  await runSessionSender();
4195
4214
  } catch (err) {
@@ -4197,7 +4216,7 @@ code is 1: revoke the token on /profile/security.
4197
4216
  }
4198
4217
  });
4199
4218
  program2.command("vm-init", { hidden: true }).description("lay out a microVM build's guest; the guest helper runs it").action(async () => {
4200
- const { realGuestHost, runGuestInit } = await import('./guest-init-WPUS45IN.js');
4219
+ const { realGuestHost, runGuestInit } = await import('./guest-init-5QZRGP62.js');
4201
4220
  const { readFileSync: readFileSync3 } = await import('fs');
4202
4221
  try {
4203
4222
  runGuestInit(realGuestHost(), readFileSync3("/proc/cmdline", "utf8"));
@@ -4206,7 +4225,7 @@ code is 1: revoke the token on /profile/security.
4206
4225
  }
4207
4226
  });
4208
4227
  program2.command("vm-forward", { hidden: true }).description("pipe a guest port to another; vm-init runs it").requiredOption("--listen <host:port>", "the address to listen on").requiredOption("--to <host:port>", "the address to pipe each connection to").action(async (opts) => {
4209
- const { startBridgeForward } = await import('./bridge-XM4QLKIX.js');
4228
+ const { startBridgeForward } = await import('./bridge-4KPODDN7.js');
4210
4229
  try {
4211
4230
  await startBridgeForward(opts);
4212
4231
  } catch (err) {
@@ -4232,7 +4251,7 @@ async function runCli(processArgv) {
4232
4251
  await buildProgram(argv).parseAsync(argv);
4233
4252
  }
4234
4253
  async function compileContext(opts) {
4235
- const { runEmit, EmitError } = await import('./emit-cmd-IOWTTZSA.js');
4254
+ const { runEmit, EmitError } = await import('./emit-cmd-RO4L4PFZ.js');
4236
4255
  try {
4237
4256
  const result = runEmit({ cwd: opts.dir, check: opts.check, json: opts.json });
4238
4257
  if (result.exitCode !== 0) process.exitCode = result.exitCode;
@@ -4285,7 +4304,7 @@ Compiling .outerlayer/ moved to \`${cliInvocation()} context emit\`.
4285
4304
  await compileContext({ dir: opts.dir, check: opts.check, json: opts.json });
4286
4305
  return;
4287
4306
  }
4288
- const { runEmitResult, EmitResultError } = await import('./emit-result-cmd-6Q7OU2NY.js');
4307
+ const { runEmitResult, EmitResultError } = await import('./emit-result-cmd-2ERWFDUN.js');
4289
4308
  try {
4290
4309
  const result = await runEmitResult({
4291
4310
  name,
@@ -4336,7 +4355,7 @@ everywhere, bytes and deep link untouched; a still-queued one is cancelled
4336
4355
  locally so it never uploads. One correction can retire several duplicates.
4337
4356
  `
4338
4357
  ).action(async (file, opts) => {
4339
- const { runEmitArtifact, EmitArtifactError } = await import('./emit-artifact-cmd-H27MFSKH.js');
4358
+ const { runEmitArtifact, EmitArtifactError } = await import('./emit-artifact-cmd-TA3MPHLU.js');
4340
4359
  let pr;
4341
4360
  if (opts.pr !== void 0) {
4342
4361
  pr = parseTrackerNumber(opts.pr);
@@ -4392,7 +4411,7 @@ its criterion, and the new record retires the old record. The id must be the ite
4392
4411
  as \`work demo --item <n> --json\` prints it.
4393
4412
  `
4394
4413
  ).action(async (manifest, opts) => {
4395
- const { runEmitDemo, EmitDemoError } = await import('./emit-demo-cmd-WJSS7KU2.js');
4414
+ const { runEmitDemo, EmitDemoError } = await import('./emit-demo-cmd-Y2Y6LEL7.js');
4396
4415
  let item;
4397
4416
  if (opts.item !== void 0) {
4398
4417
  item = parseTrackerNumber(opts.item);
@@ -4435,7 +4454,7 @@ as \`work demo --item <n> --json\` prints it.
4435
4454
  }
4436
4455
  });
4437
4456
  program2.command("demo-voice", { hidden: true }).description("Speak demo lines for a recorder: JSON lines in on stdin, out on stdout").action(async () => {
4438
- const { runDemoVoice } = await import('./demo-voice-cmd-4INIOVTC.js');
4457
+ const { runDemoVoice } = await import('./demo-voice-cmd-GEPX7GIG.js');
4439
4458
  await runDemoVoice();
4440
4459
  });
4441
4460
  const demoCmd = program2.command("demo").description("Record demos with the recorder this CLI carries");
@@ -4453,7 +4472,7 @@ and the command prints the manifest's path for \`emit demo\`. Under \`work proof
4453
4472
  to OUTERLAYER_PROOF_OUT instead. Exit 1 means the demo's test failed; its manifest is written all the same.
4454
4473
  `
4455
4474
  ).action(async (file, opts) => {
4456
- const { runDemoRecord, DemoRecordError } = await import('./demo-record-cmd-Y57UWBCX.js');
4475
+ const { runDemoRecord, DemoRecordError } = await import('./demo-record-cmd-2OKCGST7.js');
4457
4476
  try {
4458
4477
  const result = await runDemoRecord({
4459
4478
  file,
@@ -4502,7 +4521,7 @@ recent events with their ids. --find <text> searches all of them.
4502
4521
  item that session was launched for is used automatically.
4503
4522
  `
4504
4523
  ).action(async (opts) => {
4505
- const { runEmitFinding, refuseRemovedFindingFlags, EmitFindingError } = await import('./emit-finding-cmd-KQIGM5IF.js');
4524
+ const { runEmitFinding, refuseRemovedFindingFlags, EmitFindingError } = await import('./emit-finding-cmd-VECM64UR.js');
4506
4525
  try {
4507
4526
  refuseRemovedFindingFlags(opts);
4508
4527
  const result = await runEmitFinding({
@@ -4569,7 +4588,7 @@ the whole batch. "untimed": true records one with no time on purpose.
4569
4588
  that session was launched for is used automatically.
4570
4589
  `
4571
4590
  ).action(async (file, opts) => {
4572
- const { runEmitFindings, EmitFindingError } = await import('./emit-finding-cmd-KQIGM5IF.js');
4591
+ const { runEmitFindings, EmitFindingError } = await import('./emit-finding-cmd-VECM64UR.js');
4573
4592
  try {
4574
4593
  const result = await runEmitFindings({
4575
4594
  file,
@@ -4604,7 +4623,7 @@ command, the command exits 0, and \`sync\` sends it later. If the gateway refuse
4604
4623
  the step, the command prints why and exits 1.
4605
4624
  `
4606
4625
  ).action(async (name, opts) => {
4607
- const { runEmitStep, EmitStepError } = await import('./emit-step-cmd-GZU5O2FR.js');
4626
+ const { runEmitStep, EmitStepError } = await import('./emit-step-cmd-V2ET66N4.js');
4608
4627
  try {
4609
4628
  await runEmitStep({
4610
4629
  name,
@@ -4647,7 +4666,7 @@ of the item, and a (proof: <kind>) annotation names its proof.
4647
4666
  ${cliInvocation()} emit criteria acceptance/412-login.md --item 412
4648
4667
  `
4649
4668
  ).action(async (file, opts) => {
4650
- const { runEmitCriteria, EmitCriteriaError } = await import('./emit-criteria-cmd-IOUVMB2Q.js');
4669
+ const { runEmitCriteria, EmitCriteriaError } = await import('./emit-criteria-cmd-NMTUV2KM.js');
4651
4670
  try {
4652
4671
  const result = await runEmitCriteria({
4653
4672
  file,
@@ -4671,9 +4690,9 @@ function registerSpecCommands(program2) {
4671
4690
  const specCmd = program2.command("spec").description("Find, file and edit the issue a spec lives in, in your factory's tracker");
4672
4691
  const credentialOptions = (command) => command.option("--json", "machine-readable JSON output").option("--url <url>", "cloud base URL (or OUTERLAYER_URL / config)").addOption(apiKeyOption()).option("--app-id <id>", "factory id the key is bound to (or OUTERLAYER_APP_ID / config)");
4673
4692
  const run = async (action) => {
4674
- const { WorkCommandError } = await import('./work-cmd-YRPYMGII.js');
4693
+ const { WorkCommandError } = await import('./work-cmd-HKOJU5FJ.js');
4675
4694
  try {
4676
- await action(await import('./spec-cmd-CNASSB6L.js'));
4695
+ await action(await import('./spec-cmd-7QRE2SZK.js'));
4677
4696
  } catch (err) {
4678
4697
  if (err instanceof WorkCommandError) {
4679
4698
  fail(err.message);
@@ -4708,7 +4727,7 @@ Prints each problem the item covers with its id, its reports and its result.
4708
4727
  session was launched for is used.
4709
4728
  `
4710
4729
  ).action(async (opts) => {
4711
- const { runFindingsShow, FindingsCommandError } = await import('./findings-cmd-T7PQAVJG.js');
4730
+ const { runFindingsShow, FindingsCommandError } = await import('./findings-cmd-QJPPF6BY.js');
4712
4731
  try {
4713
4732
  const result = await runFindingsShow({
4714
4733
  item: opts.item,
@@ -4736,7 +4755,7 @@ Give exactly one of --fixed and --not-fixed, and a --note. Run it again for the
4736
4755
  problem to replace the earlier result. A problem the item does not cover is refused.
4737
4756
  `
4738
4757
  ).action(async (problem, opts) => {
4739
- const { runFindingsResult, FindingsCommandError } = await import('./findings-cmd-T7PQAVJG.js');
4758
+ const { runFindingsResult, FindingsCommandError } = await import('./findings-cmd-QJPPF6BY.js');
4740
4759
  try {
4741
4760
  const result = await runFindingsResult({
4742
4761
  problem,
@@ -4778,7 +4797,7 @@ takes it, and prints the line that starts your session on it. That
4778
4797
  session links itself and holds the item's lease while it works.
4779
4798
  `
4780
4799
  ).action(async (opts) => {
4781
- const { runWorkBuild, WorkCommandError } = await import('./work-cmd-YRPYMGII.js');
4800
+ const { runWorkBuild, WorkCommandError } = await import('./work-cmd-HKOJU5FJ.js');
4782
4801
  try {
4783
4802
  await runWorkBuild(opts);
4784
4803
  } catch (err) {
@@ -4801,7 +4820,7 @@ renews that session's own 20-minute lease, unless --no-lease or
4801
4820
  --ended is given, or another worker already holds a live one.
4802
4821
  `
4803
4822
  ).action(async (number, opts) => {
4804
- const { runWorkLinkSession, WorkCommandError } = await import('./work-cmd-YRPYMGII.js');
4823
+ const { runWorkLinkSession, WorkCommandError } = await import('./work-cmd-HKOJU5FJ.js');
4805
4824
  try {
4806
4825
  await runWorkLinkSession({ ...opts, number, noLease: opts.lease === false, logFailures: opts.logFailures === true });
4807
4826
  } catch (err) {
@@ -4832,8 +4851,8 @@ thread at its source. It takes a plain answer: no --criterion and no
4832
4851
  action flag.
4833
4852
  `
4834
4853
  ).action(async (opts) => {
4835
- const { runWorkComment, WorkCommentCommandError } = await import('./work-comment-cmd-U5Z6FKEU.js');
4836
- const { WorkCommandError } = await import('./work-cmd-YRPYMGII.js');
4854
+ const { runWorkComment, WorkCommentCommandError } = await import('./work-comment-cmd-H3JCWQ2J.js');
4855
+ const { WorkCommandError } = await import('./work-cmd-HKOJU5FJ.js');
4837
4856
  try {
4838
4857
  await runWorkComment(opts);
4839
4858
  } catch (err) {
@@ -4855,7 +4874,7 @@ nothing and exits 0 when the call fails: the line goes to hook-errors.log,
4855
4874
  and the comment waits for the next agent job.
4856
4875
  `
4857
4876
  ).action(async (ids, opts) => {
4858
- const { runWorkCommentsRead } = await import('./work-comment-cmd-U5Z6FKEU.js');
4877
+ const { runWorkCommentsRead } = await import('./work-comment-cmd-H3JCWQ2J.js');
4859
4878
  await runWorkCommentsRead({ ...opts, commentIds: ids });
4860
4879
  });
4861
4880
  workCmd.command("threads").description("Read a work item's general thread, its criterion threads and its source threads").requiredOption("--item <number>", "the item's number inside this factory").option("--json", "machine-readable JSON output").option("--url <url>", "cloud base URL (or OUTERLAYER_URL / config)").addOption(apiKeyOption()).option("--app-id <id>", "factory id the key is bound to (or OUTERLAYER_APP_ID / config)").addHelpText(
@@ -4871,8 +4890,8 @@ that started outside OuterLayer, such as the line comments of a
4871
4890
  GitHub review, each with its id, source and comments.
4872
4891
  `
4873
4892
  ).action(async (opts) => {
4874
- const { runWorkThreads, WorkCommentCommandError } = await import('./work-comment-cmd-U5Z6FKEU.js');
4875
- const { WorkCommandError } = await import('./work-cmd-YRPYMGII.js');
4893
+ const { runWorkThreads, WorkCommentCommandError } = await import('./work-comment-cmd-H3JCWQ2J.js');
4894
+ const { WorkCommandError } = await import('./work-cmd-HKOJU5FJ.js');
4876
4895
  try {
4877
4896
  await runWorkThreads(opts);
4878
4897
  } catch (err) {
@@ -4896,8 +4915,8 @@ still running, or that an older runner released, has no log and the
4896
4915
  command exits 1.
4897
4916
  `
4898
4917
  ).action(async (opts) => {
4899
- const { runWorkLogs, WorkLogsCommandError } = await import('./work-logs-cmd-2OA7ENDU.js');
4900
- const { WorkCommandError } = await import('./work-cmd-YRPYMGII.js');
4918
+ const { runWorkLogs, WorkLogsCommandError } = await import('./work-logs-cmd-UOO4JVLG.js');
4919
+ const { WorkCommandError } = await import('./work-cmd-HKOJU5FJ.js');
4901
4920
  try {
4902
4921
  await runWorkLogs(opts);
4903
4922
  } catch (err) {
@@ -4920,8 +4939,8 @@ item is not built again until a new build request. Exits 1 when no host
4920
4939
  build is running for the item.
4921
4940
  `
4922
4941
  ).action(async (opts) => {
4923
- const { runWorkStop, WorkStopCommandError } = await import('./work-stop-cmd-VZJX5X4L.js');
4924
- const { WorkCommandError } = await import('./work-cmd-YRPYMGII.js');
4942
+ const { runWorkStop, WorkStopCommandError } = await import('./work-stop-cmd-SD2ZRMSY.js');
4943
+ const { WorkCommandError } = await import('./work-cmd-HKOJU5FJ.js');
4925
4944
  try {
4926
4945
  await runWorkStop(opts);
4927
4946
  } catch (err) {
@@ -4942,8 +4961,8 @@ Prints the item's newest live demo record: its artifact id, the commit it was re
4942
4961
  test file that recorded it. With --json, prints { "demo": null } for an item with no demo.
4943
4962
  `
4944
4963
  ).action(async (opts) => {
4945
- const { runWorkDemo, WorkDemoCommandError } = await import('./work-demo-cmd-OLCWTVWM.js');
4946
- const { WorkCommandError } = await import('./work-cmd-YRPYMGII.js');
4964
+ const { runWorkDemo, WorkDemoCommandError } = await import('./work-demo-cmd-J4AZAIVP.js');
4965
+ const { WorkCommandError } = await import('./work-cmd-HKOJU5FJ.js');
4947
4966
  try {
4948
4967
  await runWorkDemo(opts);
4949
4968
  } catch (err) {
@@ -4964,7 +4983,7 @@ deletes anything \u2014 the item is removed from Work only once no
4964
4983
  live addition remains on it.
4965
4984
  `
4966
4985
  ).action(async (opts) => {
4967
- const { runWorkRemove, WorkCommandError } = await import('./work-cmd-YRPYMGII.js');
4986
+ const { runWorkRemove, WorkCommandError } = await import('./work-cmd-HKOJU5FJ.js');
4968
4987
  try {
4969
4988
  await runWorkRemove(opts);
4970
4989
  } catch (err) {
@@ -4976,7 +4995,7 @@ live addition remains on it.
4976
4995
  }
4977
4996
  });
4978
4997
  workCmd.command("status").description("Show one item's stage, gate ledger, and additions").option("--item <number>", "the item's number inside this factory").option("--issue <number>", "issue number, or a Linear/Jira key like ENG-123").option(TRACKER_OPTION_FLAG, "tracker for a keyed --issue, when both hold the key").option("--repo <owner/name>", "repository for an issue number (default: the checkout's remote)").option("--json", "machine-readable JSON output").option("--url <url>", "cloud base URL (or OUTERLAYER_URL / config)").addOption(apiKeyOption()).option("--app-id <id>", "factory id the key is bound to (or OUTERLAYER_APP_ID / config)").action(async (opts) => {
4979
- const { runWorkStatus, WorkCommandError } = await import('./work-cmd-YRPYMGII.js');
4998
+ const { runWorkStatus, WorkCommandError } = await import('./work-cmd-HKOJU5FJ.js');
4980
4999
  try {
4981
5000
  await runWorkStatus(opts);
4982
5001
  } catch (err) {
@@ -5021,11 +5040,11 @@ differs from HEAD.
5021
5040
  fail(trackerNumberError("--pr", opts.pr));
5022
5041
  return;
5023
5042
  }
5024
- const { runWorkProofsCommand } = await import('./work-proofs-cmd-BUOS5OJC.js');
5043
+ const { runWorkProofsCommand } = await import('./work-proofs-cmd-7Y3HGT7C.js');
5025
5044
  await runWorkProofsCommand({ ...opts, ...pr === void 0 ? {} : { pr } });
5026
5045
  });
5027
5046
  workCmd.command("list").description("List live work items for this factory").option("--stage <spec|build|review>", "filter by stage").option("--section <attention|waiting|flowing>", "filter by Queue section").option("--repo <owner/name>", "repository (default: the current checkout's remote)").option("--unclaimed", "only items with no live lease").option("--claimed", "only items with a live lease, held by a host or a local session").option("--startable", "only items a host can start: a build request, no open PR, no live lease").option("--needs <amend>", "only items with a thread waiting on an agent").option("--json", "machine-readable JSON output").option("--url <url>", "cloud base URL (or OUTERLAYER_URL / config)").addOption(apiKeyOption()).option("--app-id <id>", "factory id the key is bound to (or OUTERLAYER_APP_ID / config)").action(async (opts) => {
5028
- const { runWorkList, WorkCommandError } = await import('./work-cmd-YRPYMGII.js');
5047
+ const { runWorkList, WorkCommandError } = await import('./work-cmd-HKOJU5FJ.js');
5029
5048
  try {
5030
5049
  await runWorkList(opts);
5031
5050
  } catch (err) {
@@ -5046,7 +5065,7 @@ by a different key is refused; claiming again with the same key extends
5046
5065
  it. --host is a label only.
5047
5066
  `
5048
5067
  ).action(async (opts) => {
5049
- const { runWorkClaim, WorkCommandError } = await import('./work-claim-cmd-GUYOJYH7.js');
5068
+ const { runWorkClaim, WorkCommandError } = await import('./work-claim-cmd-WGTSU5IT.js');
5050
5069
  try {
5051
5070
  await runWorkClaim(opts);
5052
5071
  } catch (err) {
@@ -5066,7 +5085,7 @@ Extends the live lease this API key holds. Refused with a 410 if the
5066
5085
  lease has expired, or a 403 if a different key holds it.
5067
5086
  `
5068
5087
  ).action(async (opts) => {
5069
- const { runWorkRenew, WorkCommandError } = await import('./work-claim-cmd-GUYOJYH7.js');
5088
+ const { runWorkRenew, WorkCommandError } = await import('./work-claim-cmd-WGTSU5IT.js');
5070
5089
  try {
5071
5090
  await runWorkRenew(opts);
5072
5091
  } catch (err) {
@@ -5098,7 +5117,7 @@ applies to a host's lease only. A later tool call in the session
5098
5117
  takes the lease again.
5099
5118
  `
5100
5119
  ).action(async (opts) => {
5101
- const { runWorkRelease, WorkCommandError } = await import('./work-claim-cmd-GUYOJYH7.js');
5120
+ const { runWorkRelease, WorkCommandError } = await import('./work-claim-cmd-WGTSU5IT.js');
5102
5121
  try {
5103
5122
  await runWorkRelease(opts);
5104
5123
  } catch (err) {
@@ -5125,7 +5144,7 @@ Idempotent: declaring the same pull request twice is a no-op.
5125
5144
  needs your own login; an agent session or a factory key is refused.
5126
5145
  `
5127
5146
  ).action(async (number, opts) => {
5128
- const { runWorkPr, WorkPrCommandError } = await import('./work-pr-cmd-KK3VQUQI.js');
5147
+ const { runWorkPr, WorkPrCommandError } = await import('./work-pr-cmd-3Q2D5RQT.js');
5129
5148
  try {
5130
5149
  await runWorkPr({ ...opts, number });
5131
5150
  } catch (err) {
@@ -5150,8 +5169,8 @@ login, then declares the pull request on the item, as \`work pr\` does.
5150
5169
  Run it again after a change to the title or description.
5151
5170
  `
5152
5171
  ).action(async (opts) => {
5153
- const { runWorkOpenPr, WorkOpenPrCommandError } = await import('./work-open-pr-cmd-6GUCDYVM.js');
5154
- const { WorkCommandError } = await import('./work-cmd-YRPYMGII.js');
5172
+ const { runWorkOpenPr, WorkOpenPrCommandError } = await import('./work-open-pr-cmd-QFRDDBAM.js');
5173
+ const { WorkCommandError } = await import('./work-cmd-HKOJU5FJ.js');
5155
5174
  try {
5156
5175
  await runWorkOpenPr(opts);
5157
5176
  } catch (err) {
@@ -5167,9 +5186,9 @@ function registerRunnerCommands(program2) {
5167
5186
  const runnerCmd = program2.command("runner").description("Take work from the implement and amend queues on this machine");
5168
5187
  const configOption = "the cloud config file to run against (default: ~/.outerlayer/config.json)";
5169
5188
  runnerCmd.command("start").description("Run the loop: claim work, run it, report, clean up, repeat").option("--config <path>", configOption).action(async (opts) => {
5170
- const { defaultRunnerConfigPath, RunnerConfigError } = await import('./config-5GY7FL35.js');
5171
- const { start, RunnerStartError } = await import('./loop-KDWDOSMQ.js');
5172
- const { RunnerAlreadyRunningError } = await import('./pidfile-FLFVRKVW.js');
5189
+ const { defaultRunnerConfigPath, RunnerConfigError } = await import('./config-T22KVOOT.js');
5190
+ const { start, RunnerStartError } = await import('./loop-L6TX6OR4.js');
5191
+ const { RunnerAlreadyRunningError } = await import('./pidfile-7M7O2M7T.js');
5173
5192
  const configPath = opts.config ?? defaultRunnerConfigPath();
5174
5193
  try {
5175
5194
  const { realUpdateDeps } = await import('./real-deps-QX5YH7FG.js');
@@ -5186,10 +5205,10 @@ function registerRunnerCommands(program2) {
5186
5205
  "after",
5187
5206
  "\nReads OUTERLAYER_URL, OUTERLAYER_APP_ID, OUTERLAYER_API_KEY, OUTERLAYER_RUNNER_NAME and one Claude credential\n(CLAUDE_CODE_OAUTH_TOKEN or ANTHROPIC_API_KEY) from the environment. OUTERLAYER_AGENT\nis optional and defaults to claude. On a later start it refuses variables that disagree with the config in the volume.\nThe image sets OUTERLAYER_RUNNER_IMAGE; outside the image, use `runner start`.\n"
5188
5207
  ).action(async () => {
5189
- const { defaultRunnerConfigPath, RunnerConfigError } = await import('./config-5GY7FL35.js');
5190
- const { containerStart } = await import('./container-start-OCJODSMB.js');
5191
- const { start, RunnerStartError } = await import('./loop-KDWDOSMQ.js');
5192
- const { RunnerAlreadyRunningError } = await import('./pidfile-FLFVRKVW.js');
5208
+ const { defaultRunnerConfigPath, RunnerConfigError } = await import('./config-T22KVOOT.js');
5209
+ const { containerStart } = await import('./container-start-JRF3SBUA.js');
5210
+ const { start, RunnerStartError } = await import('./loop-L6TX6OR4.js');
5211
+ const { RunnerAlreadyRunningError } = await import('./pidfile-7M7O2M7T.js');
5193
5212
  try {
5194
5213
  const result = await containerStart({
5195
5214
  env: process.env,
@@ -5210,16 +5229,16 @@ function registerRunnerCommands(program2) {
5210
5229
  "after",
5211
5230
  "\nIn the runner image, run it with `docker exec <container> outerlayer runner update-steps`. It reads the\ncontainer with `docker inspect` and changes nothing. The steps rename the old container and never remove it\nbefore the new one runs. They name the container's variables and never print a value.\n"
5212
5231
  ).action(async (opts) => {
5213
- const { defaultRunnerConfigPath } = await import('./config-5GY7FL35.js');
5214
- const { runnerDir } = await import('./paths-XEYE7OZ2.js');
5215
- const { runUpdateSteps } = await import('./update-steps-XGOXDCOS.js');
5232
+ const { defaultRunnerConfigPath } = await import('./config-T22KVOOT.js');
5233
+ const { runnerDir } = await import('./paths-F2ZR2EKC.js');
5234
+ const { runUpdateSteps } = await import('./update-steps-VGKNGWTZ.js');
5216
5235
  const text = await runUpdateSteps({ runnerDirPath: runnerDir(opts.config ?? defaultRunnerConfigPath()) });
5217
5236
  process.stdout.write(`${text}
5218
5237
  `);
5219
5238
  });
5220
5239
  runnerCmd.command("check").description("Validate the config, the hooks and the key, and print the effective settings").option("--config <path>", configOption).action(async (opts) => {
5221
- const { defaultRunnerConfigPath } = await import('./config-5GY7FL35.js');
5222
- const { runRunnerCheck } = await import('./check-K4RVAP4L.js');
5240
+ const { defaultRunnerConfigPath } = await import('./config-T22KVOOT.js');
5241
+ const { runRunnerCheck } = await import('./check-WWX32IGY.js');
5223
5242
  const configPath = opts.config ?? defaultRunnerConfigPath();
5224
5243
  const result = await runRunnerCheck(configPath);
5225
5244
  if (!result.ok) {
@@ -5240,8 +5259,8 @@ function registerRunnerCommands(program2) {
5240
5259
  `);
5241
5260
  });
5242
5261
  runnerCmd.command("install").description("Put this CLI in the runner's install layout; --service adds its service").option("--config <path>", configOption).option("--service", "set up the service that keeps the runner running").option("--print", "with --service, print the unit and set up nothing").option("--user <account>", "with --service, the account the service runs as").option("--replace", "replace a unit or launcher file this command did not write").option("--allow-downgrade", "install this CLI even when it is older than the version the runner runs").option("--unit-name <name>", "with --service, the unit's name, to run a second runner beside the first").option("--build-memory-max <size>", "with --service, memory all builds may use together, such as 16g").option("--build-cpus-max <n>", "with --service, CPUs all builds may use together, such as 4").action(async (opts) => {
5243
- const { defaultRunnerConfigPath, RunnerConfigError } = await import('./config-5GY7FL35.js');
5244
- const { runRunnerInstall, RunnerInstallError, launcherSummary, restartNote } = await import('./install-cmd-JKPXIOEY.js');
5262
+ const { defaultRunnerConfigPath, RunnerConfigError } = await import('./config-T22KVOOT.js');
5263
+ const { runRunnerInstall, RunnerInstallError, launcherSummary, restartNote } = await import('./install-cmd-RHFUZFV4.js');
5245
5264
  const configPath = opts.config ?? defaultRunnerConfigPath();
5246
5265
  if (opts.service !== true) {
5247
5266
  const names = { print: "print", user: "user", unitName: "unit-name", buildMemoryMax: "build-memory-max", buildCpusMax: "build-cpus-max" };
@@ -5253,13 +5272,13 @@ function registerRunnerCommands(program2) {
5253
5272
  }
5254
5273
  }
5255
5274
  const buildCpusMax = opts.buildCpusMax === void 0 ? void 0 : Number(opts.buildCpusMax);
5256
- if (buildCpusMax !== void 0 && !(await import('./command-QLHQZ32L.js')).cpusAreValid(buildCpusMax)) {
5275
+ if (buildCpusMax !== void 0 && !(await import('./command-CGEFJZNC.js')).cpusAreValid(buildCpusMax)) {
5257
5276
  fail(`--build-cpus-max ${opts.buildCpusMax} is not a number of CPUs from 0.01 to 1024.`);
5258
5277
  return;
5259
5278
  }
5260
5279
  try {
5261
5280
  if (opts.service === true) {
5262
- const { installServiceCommand } = await import('./command-QLHQZ32L.js');
5281
+ const { installServiceCommand } = await import('./command-CGEFJZNC.js');
5263
5282
  const result2 = await installServiceCommand({
5264
5283
  configPath,
5265
5284
  print: opts.print,
@@ -5316,8 +5335,8 @@ To keep it running, run ${C.yellow}${cliInvocation()} runner install --service${
5316
5335
  fail(`pass --service: \`${cliInvocation()} runner uninstall --service\` removes the runner's service.`);
5317
5336
  return;
5318
5337
  }
5319
- const { defaultRunnerConfigPath } = await import('./config-5GY7FL35.js');
5320
- const { uninstallServiceCommand } = await import('./command-QLHQZ32L.js');
5338
+ const { defaultRunnerConfigPath } = await import('./config-T22KVOOT.js');
5339
+ const { uninstallServiceCommand } = await import('./command-CGEFJZNC.js');
5321
5340
  const result = await uninstallServiceCommand({ configPath: opts.config ?? defaultRunnerConfigPath(), unitName: opts.unitName, home: homeFromEnv() });
5322
5341
  if (result.ok) for (const line of result.lines) process.stdout.write(`${C.green}\u2713${C.reset} ${line}
5323
5342
  `);
@@ -5344,12 +5363,12 @@ already in claude.env is used.
5344
5363
  printf '%s' "$CLAUDE_CODE_OAUTH_TOKEN" | ${cliInvocation()} runner init --agent claude --factory <org>/<factory>
5345
5364
  `
5346
5365
  ).action(async (opts) => {
5347
- const { defaultRunnerConfigPath, RunnerConfigError } = await import('./config-5GY7FL35.js');
5348
- const { prepareRunnerInit, runRunnerInit, RunnerInitError, writeRunnerInit } = await import('./init-ILTX4V56.js');
5349
- const { obtainRunnerKey, runnerKeyLogin } = await import('./runner-key-CFZ47PR3.js');
5350
- const { detectMachine } = await import('./machine-Z6K5XXI6.js');
5351
- const { chooseVm, runVmInit, VmInitError } = await import('./init-HUQLVUPO.js');
5352
- const { AGENT_COMMANDS, credentialFromStdin, isAgentName, restartForCredential, RunnerEnvError } = await import('./runner-env-W2UMHY7P.js');
5366
+ const { defaultRunnerConfigPath, RunnerConfigError } = await import('./config-T22KVOOT.js');
5367
+ const { prepareRunnerInit, runRunnerInit, RunnerInitError, writeRunnerInit } = await import('./init-EK3PUU6W.js');
5368
+ const { obtainRunnerKey, runnerKeyLogin } = await import('./runner-key-R47C6374.js');
5369
+ const { detectMachine } = await import('./machine-VJKAY2GX.js');
5370
+ const { chooseVm, runVmInit, VmInitError } = await import('./init-Y2URPVVY.js');
5371
+ const { AGENT_COMMANDS, credentialFromStdin, isAgentName, restartForCredential, RunnerEnvError } = await import('./runner-env-YW55JVU7.js');
5353
5372
  const configPath = opts.config ?? defaultRunnerConfigPath();
5354
5373
  if (opts.agent !== void 0 && !isAgentName(opts.agent)) {
5355
5374
  fail(`--agent ${opts.agent}: runner init writes commands for ${Object.keys(AGENT_COMMANDS).join(", ")}. For another agent, leave --agent out and edit runner.commands.`);
@@ -5380,7 +5399,7 @@ already in claude.env is used.
5380
5399
  const chunks = [];
5381
5400
  for await (const chunk of process.stdin) chunks.push(Buffer.from(chunk));
5382
5401
  const result2 = runRunnerInit(configPath, { machine, configFromStdin: Buffer.concat(chunks).toString("utf8"), requireContainer: true });
5383
- const { ensureHostKey: ensureHostKey2 } = await import('./host-key-O4DFMOSV.js');
5402
+ const { ensureHostKey: ensureHostKey2 } = await import('./host-key-HLLV37NV.js');
5384
5403
  const hostKey2 = await ensureHostKey2(configPath);
5385
5404
  process.stdout.write(`host key ${hostKey2.fingerprint}
5386
5405
  hooks: ${result2.hooks}
@@ -5439,7 +5458,7 @@ hooks: ${result2.hooks}
5439
5458
  const prepared = prepareRunnerInit(configPath, { machine, allowProcess, agent, credential, keyFromLogin: makeKey !== void 0 });
5440
5459
  const created = makeKey === void 0 ? void 0 : await makeKey();
5441
5460
  const result = writeRunnerInit(prepared, created);
5442
- const { ensureHostKey } = await import('./host-key-O4DFMOSV.js');
5461
+ const { ensureHostKey } = await import('./host-key-HLLV37NV.js');
5443
5462
  const hostKey = await ensureHostKey(configPath);
5444
5463
  if (created !== void 0) {
5445
5464
  process.stdout.write(`${C.green}\u2713${C.reset} saved the runner key in ${result.configPath}
@@ -5467,7 +5486,7 @@ ${C.yellow}${result.note}${C.reset}
5467
5486
  To isolate builds in containers instead, run ${C.yellow}${cliInvocation()} runner init --vm${C.reset}.
5468
5487
  `);
5469
5488
  }
5470
- const { runRunnerInstall, RunnerInstallError, RunnerDowngradeError, launcherSummary } = await import('./install-cmd-JKPXIOEY.js');
5489
+ const { runRunnerInstall, RunnerInstallError, RunnerDowngradeError, launcherSummary } = await import('./install-cmd-RHFUZFV4.js');
5471
5490
  let installedLayout = false;
5472
5491
  let noService = "it starts the runner from the install layout, which needs a CLI installed with npm";
5473
5492
  try {
@@ -5499,7 +5518,7 @@ ${C.yellow}The runner will not update itself: ${installErr.message}${C.reset}
5499
5518
  let serviceUp = false;
5500
5519
  let restart;
5501
5520
  if (installedLayout) {
5502
- const { installServiceCommand } = await import('./command-QLHQZ32L.js');
5521
+ const { installServiceCommand } = await import('./command-CGEFJZNC.js');
5503
5522
  const service = await installServiceCommand({
5504
5523
  configPath,
5505
5524
  entryPath: process.argv[1] ?? "",
@@ -5543,12 +5562,12 @@ Next:
5543
5562
  "after",
5544
5563
  "\nA repository governed by a control plane builds the control plane's image, at the commit\nthe gateway has stored for it. A repository that governs itself fetches the head of its\ndefault branch into the runner's cache. Either way it reads .devcontainer/devcontainer.json\nand builds the image with the devcontainer CLI. Settings\nthat reach the host or widen the container's privileges are ignored and listed. The\nimage holds this CLI and a pinned Claude Code. Nothing runs inside the image.\nA repository with no devcontainer file builds on the universal image the CLI pins by digest.\n"
5545
5564
  ).action(async (opts) => {
5546
- const { defaultRunnerConfigPath } = await import('./config-5GY7FL35.js');
5547
- const { baseLines, buildRepositoryImage, RecipeError } = await import('./build-ZE5IG3V6.js');
5565
+ const { defaultRunnerConfigPath } = await import('./config-T22KVOOT.js');
5566
+ const { baseLines, buildRepositoryImage, RecipeError } = await import('./build-KYXFZQ33.js');
5548
5567
  const { currentCliBuild } = await import('./cli-build-K56DK4DS.js');
5549
- const { createDockerHost } = await import('./docker-5YVUZ3J2.js');
5550
- const { builderSpec } = await import('./builder-LJ3FSB36.js');
5551
- const { loadRunnerConfig } = await import('./config-5GY7FL35.js');
5568
+ const { createDockerHost } = await import('./docker-5VWK335X.js');
5569
+ const { builderSpec } = await import('./builder-IMNOEYV7.js');
5570
+ const { loadRunnerConfig } = await import('./config-T22KVOOT.js');
5552
5571
  const configPath = opts.config ?? defaultRunnerConfigPath();
5553
5572
  const loaded = (() => {
5554
5573
  try {
@@ -5559,12 +5578,12 @@ Next:
5559
5578
  })();
5560
5579
  const memory = loaded?.build?.memory ?? "8g";
5561
5580
  try {
5562
- const { ensureRunnerIdentity } = await import('./runner-identity-IIY5UJL3.js');
5581
+ const { ensureRunnerIdentity } = await import('./runner-identity-Y5ZFCC7V.js');
5563
5582
  await ensureRunnerIdentity(configPath, { log: (line) => console.error(line) }).catch((err) => {
5564
5583
  console.error(`the runner's Docker identity could not be stored: ${err instanceof Error ? err.message : String(err)}`);
5565
5584
  });
5566
- const { imageTargetFor } = await import('./governing-source-CND5ZZC3.js');
5567
- const { runnerCalls } = await import('./caller-YLNJJPFU.js');
5585
+ const { imageTargetFor } = await import('./governing-source-7PZ6DAJU.js');
5586
+ const { runnerCalls } = await import('./caller-NLRE272L.js');
5568
5587
  const target = await imageTargetFor({ config: loaded === void 0 || loaded.fleet === true ? void 0 : runnerCalls(loaded), repository: opts.repository, fetchImpl: fetch });
5569
5588
  if (!target.ok) {
5570
5589
  if (opts.json) {
@@ -5628,25 +5647,25 @@ Next:
5628
5647
  }
5629
5648
  });
5630
5649
  runnerCmd.command("stop").description("Take no more work; finish running jobs, then exit").option("--config <path>", "the cloud config file naming the runner to stop").option("--now", "end running jobs immediately, with outcome stopped").action(async (opts) => {
5631
- const { defaultRunnerConfigPath } = await import('./config-5GY7FL35.js');
5632
- const { requestStop } = await import('./loop-KDWDOSMQ.js');
5650
+ const { defaultRunnerConfigPath } = await import('./config-T22KVOOT.js');
5651
+ const { requestStop } = await import('./loop-L6TX6OR4.js');
5633
5652
  const configPath = opts.config ?? defaultRunnerConfigPath();
5634
- const { runnerImageVersion } = await import('./image-tag-WBD57QBN.js');
5653
+ const { runnerImageVersion } = await import('./image-tag-PBWQBATH.js');
5635
5654
  await requestStop(configPath, Boolean(opts.now), void 0, { image: runnerImageVersion() !== void 0 });
5636
5655
  });
5637
5656
  runnerCmd.command("status").description("List running jobs; with --recent, finished ones too").option("--config <path>", "the cloud config file naming the runner to inspect").option("--recent", "also list finished jobs, newest first, capped at 20").option("--json", "machine-readable JSON output").action(async (opts) => {
5638
- const { defaultRunnerConfigPath, loadRunnerConfig } = await import('./config-5GY7FL35.js');
5639
- const { jobsDir, runnerDir } = await import('./paths-XEYE7OZ2.js');
5640
- const { listJobFiles, runnerProcessState } = await import('./loop-KDWDOSMQ.js');
5641
- const { renderStatus } = await import('./status-VNHIHQ57.js');
5642
- const { readHousekeepingRecord } = await import('./record-JMZOXD4R.js');
5657
+ const { defaultRunnerConfigPath, loadRunnerConfig } = await import('./config-T22KVOOT.js');
5658
+ const { jobsDir, runnerDir } = await import('./paths-F2ZR2EKC.js');
5659
+ const { listJobFiles, runnerProcessState } = await import('./loop-L6TX6OR4.js');
5660
+ const { renderStatus } = await import('./status-BQEYEG2V.js');
5661
+ const { readHousekeepingRecord } = await import('./record-YCJ6DZOY.js');
5643
5662
  const path2 = await import('path');
5644
5663
  const configPath = opts.config ?? defaultRunnerConfigPath();
5645
5664
  const all = listJobFiles(configPath);
5646
5665
  const housekeeping = readHousekeepingRecord(runnerDir(configPath));
5647
- const { readPendingUpdate } = await import('./pending-D2NNV54J.js');
5666
+ const { readPendingUpdate } = await import('./pending-VOFQRXP4.js');
5648
5667
  const pendingUpdate = readPendingUpdate(runnerDir(configPath));
5649
- const { readImageStatus } = await import('./image-tag-WBD57QBN.js');
5668
+ const { readImageStatus } = await import('./image-tag-PBWQBATH.js');
5650
5669
  const image = readImageStatus(runnerDir(configPath));
5651
5670
  let host = "unknown";
5652
5671
  let concurrency = 1;
@@ -5656,7 +5675,7 @@ Next:
5656
5675
  host = config.host;
5657
5676
  concurrency = config.concurrency;
5658
5677
  if (config.fleet === true) {
5659
- const { readFleetState } = await import('./state-UWIM42JH.js');
5678
+ const { readFleetState } = await import('./state-VAHBIMS5.js');
5660
5679
  fleet = { state: readFleetState(configPath) };
5661
5680
  }
5662
5681
  } catch {
@@ -5664,7 +5683,7 @@ Next:
5664
5683
  const processState = runnerProcessState(configPath);
5665
5684
  const service = await (async () => {
5666
5685
  if (process.platform !== "linux" || !existsSync("/run/systemd/system")) return void 0;
5667
- const { inspectRunnerService } = await import('./find-unit-PRZIFBIK.js');
5686
+ const { inspectRunnerService } = await import('./find-unit-CNAPU7XQ.js');
5668
5687
  const facts = inspectRunnerService(configPath);
5669
5688
  return facts === void 0 ? void 0 : { unit: facts.unit, running: facts.mainPid !== void 0, delegated: facts.delegate };
5670
5689
  })();
@@ -5703,9 +5722,9 @@ Next:
5703
5722
  );
5704
5723
  });
5705
5724
  runnerCmd.command("logs").argument("<item>", "the work item's number in the factory, or a build's claim id").description("Print the newest attempt's log for one item or claim id").option("--config <path>", "the cloud config file naming the runner to inspect").option("-f, --follow", "keep printing as the log grows").action(async (itemArg, opts) => {
5706
- const { defaultRunnerConfigPath } = await import('./config-5GY7FL35.js');
5707
- const { listJobFiles } = await import('./loop-KDWDOSMQ.js');
5708
- const { describeAmbiguous, logPathFor, selectAttempt, tail, RunnerLogsError } = await import('./logs-FEITSC2V.js');
5725
+ const { defaultRunnerConfigPath } = await import('./config-T22KVOOT.js');
5726
+ const { listJobFiles } = await import('./loop-L6TX6OR4.js');
5727
+ const { describeAmbiguous, logPathFor, selectAttempt, tail, RunnerLogsError } = await import('./logs-E7MGQINH.js');
5709
5728
  const configPath = opts.config ?? defaultRunnerConfigPath();
5710
5729
  const jobs = listJobFiles(configPath);
5711
5730
  const selected = selectAttempt(jobs, itemArg);
@@ -5743,28 +5762,35 @@ function registerHooksCommands(program2) {
5743
5762
  );
5744
5763
  hooksCmd.command("status").description("List hook entries in user and project settings, marking the wrapped ones").option("--json", "machine-readable JSON output").action((opts) => {
5745
5764
  const report = [];
5746
- for (const scope of ["user", "project"]) {
5747
- const path2 = settingsPath(scope);
5748
- let settings;
5749
- try {
5750
- settings = readSettings(path2);
5751
- } catch (err) {
5752
- if (err instanceof SettingsParseError) {
5753
- report.push({ scope, path: path2, error: err.message, entries: [] });
5754
- continue;
5765
+ const where = { home: homeFromEnv(), cwd: process.cwd() };
5766
+ const cli = cliForInstall(resolveCliBin());
5767
+ const agents = installAgents();
5768
+ for (const agent of agents) {
5769
+ const named = agent === agents[0] ? {} : { agent: agent.entry.descriptor.id };
5770
+ for (const scope of ["user", "project"]) {
5771
+ const path2 = settingsFileOf(agent, scope, where);
5772
+ let candidates;
5773
+ try {
5774
+ candidates = withSettingsText(path2, (text) => agent.install.candidates(text, cli));
5775
+ } catch (err) {
5776
+ if (err instanceof SettingsParseError) {
5777
+ report.push({ scope, path: path2, ...named, error: err.message, entries: [] });
5778
+ continue;
5779
+ }
5780
+ throw err;
5755
5781
  }
5756
- throw err;
5782
+ report.push({
5783
+ scope,
5784
+ path: path2,
5785
+ ...named,
5786
+ entries: candidates.map((c) => ({
5787
+ event: c.event,
5788
+ ...c.matcher ? { matcher: c.matcher } : {},
5789
+ command: c.command,
5790
+ wrapped: c.wrapped
5791
+ }))
5792
+ });
5757
5793
  }
5758
- report.push({
5759
- scope,
5760
- path: path2,
5761
- entries: listHookCandidates(settings, resolveCliBin()).map((c) => ({
5762
- event: c.event,
5763
- ...c.matcher ? { matcher: c.matcher } : {},
5764
- command: c.command,
5765
- wrapped: c.wrapped
5766
- }))
5767
- });
5768
5794
  }
5769
5795
  if (opts.json) {
5770
5796
  writeJson(report);
@@ -5807,94 +5833,97 @@ ${C.dim}${file.path}${C.reset}
5807
5833
  fail(`could not copy the CLI to ~/.outerlayer/cli: ${err instanceof Error ? err.message : String(err)}`);
5808
5834
  return;
5809
5835
  }
5810
- const path2 = settingsPath(scope);
5811
- let settings;
5812
- try {
5813
- settings = readSettings(path2);
5814
- } catch (err) {
5815
- if (err instanceof SettingsParseError) {
5816
- fail(err.message);
5817
- return;
5836
+ const where = { home: homeFromEnv(), cwd: process.cwd() };
5837
+ for (const agent of installAgents()) {
5838
+ const path2 = settingsFileOf(agent, scope, where);
5839
+ const readCli = cliForInstall(resolveCliBin());
5840
+ let candidates;
5841
+ try {
5842
+ candidates = withSettingsText(path2, (text2) => agent.install.candidates(text2, readCli));
5843
+ } catch (err) {
5844
+ if (err instanceof SettingsParseError) {
5845
+ fail(err.message);
5846
+ continue;
5847
+ }
5848
+ throw err;
5818
5849
  }
5819
- throw err;
5820
- }
5821
- const events = opts.event ? [opts.event] : void 0;
5822
- const candidates = listHookCandidates(settings, resolveCliBin()).filter(
5823
- (c) => !c.wrapped && (!events || events.includes(c.event))
5824
- );
5825
- if (candidates.length === 0) {
5826
- process.stdout.write(`${C.dim}No unwrapped hook candidates in ${path2}${C.reset}
5850
+ const events = opts.event ? [opts.event] : void 0;
5851
+ const unwrapped = candidates.filter((c) => !c.wrapped && (!events || events.includes(c.event)));
5852
+ if (unwrapped.length === 0) {
5853
+ process.stdout.write(`${C.dim}No unwrapped hook candidates in ${path2}${C.reset}
5827
5854
  `);
5828
- return;
5829
- }
5830
- let accept;
5831
- if (opts.all) {
5832
- accept = () => true;
5833
- } else {
5834
- const rl = createInterface({ input: process.stdin, output: process.stdout });
5835
- const accepted = /* @__PURE__ */ new Set();
5836
- for (const c of candidates) {
5837
- const answer = await rl.question(
5838
- `Wrap ${c.event}${c.matcher ? `[${c.matcher}]` : ""}: ${c.command} ? [y/N] `
5839
- );
5840
- if (/^y(es)?$/i.test(answer.trim())) accepted.add(candidateKey(c));
5855
+ continue;
5841
5856
  }
5842
- rl.close();
5843
- accept = (c) => accepted.has(candidateKey(c));
5844
- }
5845
- const { next, changed, wrapped, skippedUnresolvedBin } = wrapHooks(settings, cliBin, {
5846
- events,
5847
- captureOutput: opts.captureOutput,
5848
- select: accept
5849
- });
5850
- if (skippedUnresolvedBin) {
5851
- fail(
5852
- `the resolved CLI path (${cliBin}) does not exist \u2014 refusing to write hook entries pointing at it.
5853
- Reinstall OuterLayer, then re-run this command.`
5857
+ let accept;
5858
+ if (opts.all) {
5859
+ accept = () => true;
5860
+ } else {
5861
+ const rl = createInterface({ input: process.stdin, output: process.stdout });
5862
+ const accepted = /* @__PURE__ */ new Set();
5863
+ for (const c of unwrapped) {
5864
+ const answer = await rl.question(
5865
+ `Wrap ${c.event}${c.matcher ? `[${c.matcher}]` : ""}: ${c.command} ? [y/N] `
5866
+ );
5867
+ if (/^y(es)?$/i.test(answer.trim())) accepted.add(candidateKey(c));
5868
+ }
5869
+ rl.close();
5870
+ accept = (c) => accepted.has(candidateKey(c));
5871
+ }
5872
+ const { text, changed, wrapped, skippedUnresolvedBin } = withSettingsText(
5873
+ path2,
5874
+ (current) => agent.install.wrap(current, cliForInstall(cliBin), { events, captureOutput: opts.captureOutput, select: accept })
5854
5875
  );
5855
- return;
5856
- }
5857
- if (!changed) {
5858
- process.stdout.write(`${C.dim}No hooks wrapped${C.reset}
5876
+ if (skippedUnresolvedBin) {
5877
+ fail(
5878
+ `the resolved CLI path (${cliBin}) does not exist \u2014 refusing to write hook entries pointing at it.
5879
+ Reinstall OuterLayer, then re-run this command.`
5880
+ );
5881
+ return;
5882
+ }
5883
+ if (!changed) {
5884
+ process.stdout.write(`${C.dim}No hooks wrapped${C.reset}
5859
5885
  `);
5860
- return;
5861
- }
5862
- const backupPath = writeSettings(path2, next);
5863
- const manifestHome = homeFromEnv();
5864
- recordWrapped(manifestHome, path2, wrapped.map((c) => ({ event: c.event, original: c.command })));
5865
- process.stdout.write(
5866
- `${C.green}\u2713${C.reset} Wrapped ${wrapped.length} hook(s) in ${path2}
5886
+ continue;
5887
+ }
5888
+ const backupPath = writeSettingsText(path2, text);
5889
+ const manifestHome = homeFromEnv();
5890
+ recordWrapped(manifestHome, path2, wrapped.map((c) => ({ event: c.event, original: c.command })));
5891
+ process.stdout.write(
5892
+ `${C.green}\u2713${C.reset} Wrapped ${wrapped.length} hook(s) in ${path2}
5867
5893
  ` + (backupPath ? `${C.dim} backup: ${backupPath}${C.reset}
5868
5894
  ` : "")
5869
- );
5895
+ );
5896
+ }
5870
5897
  });
5871
5898
  hooksCmd.command("unwrap").description("Restore wrapped hooks to their original commands").option("--project", "operate on project settings instead of user settings").addHelpText("after", "\nAlso the escape hatch if the wrapper misbehaves.\n").action((opts) => {
5872
5899
  const scope = opts.project ? "project" : "user";
5873
- const path2 = settingsPath(scope);
5874
- let settings;
5875
- try {
5876
- settings = readSettings(path2);
5877
- } catch (err) {
5878
- if (err instanceof SettingsParseError) {
5879
- fail(err.message);
5880
- return;
5900
+ const where = { home: homeFromEnv(), cwd: process.cwd() };
5901
+ for (const agent of installAgents()) {
5902
+ const path2 = settingsFileOf(agent, scope, where);
5903
+ let result;
5904
+ try {
5905
+ result = withSettingsText(path2, (text) => agent.install.unwrap(text, cliForInstall(resolveCliBin())));
5906
+ } catch (err) {
5907
+ if (err instanceof SettingsParseError) {
5908
+ fail(err.message);
5909
+ continue;
5910
+ }
5911
+ throw err;
5881
5912
  }
5882
- throw err;
5883
- }
5884
- const { next, changed, unwrapped } = unwrapHooks(settings, resolveCliBin());
5885
- const manifestHome = homeFromEnv();
5886
- recordUnwrapped(manifestHome, path2);
5887
- if (!changed) {
5888
- process.stdout.write(`${C.dim}No wrapped hooks in ${path2}${C.reset}
5913
+ const manifestHome = homeFromEnv();
5914
+ recordUnwrapped(manifestHome, path2);
5915
+ if (!result.changed) {
5916
+ process.stdout.write(`${C.dim}No wrapped hooks in ${path2}${C.reset}
5889
5917
  `);
5890
- return;
5891
- }
5892
- const backupPath = writeSettings(path2, next);
5893
- process.stdout.write(
5894
- `${C.green}\u2713${C.reset} Restored ${unwrapped} hook(s) in ${path2}
5918
+ continue;
5919
+ }
5920
+ const backupPath = writeSettingsText(path2, result.text);
5921
+ process.stdout.write(
5922
+ `${C.green}\u2713${C.reset} Restored ${result.unwrapped} hook(s) in ${path2}
5895
5923
  ` + (backupPath ? `${C.dim} backup: ${backupPath}${C.reset}
5896
5924
  ` : "")
5897
- );
5925
+ );
5926
+ }
5898
5927
  });
5899
5928
  }
5900
5929
  function registerMcpCommands(program2) {
@@ -5916,7 +5945,7 @@ Self-host deployments also need --app-id: without a key service to resolve the
5916
5945
  caller from the bearer token, the gateway answers 401 without that header.
5917
5946
  `
5918
5947
  ).action(async (opts) => {
5919
- const { runMcpInstall, handleMcpInstallError, McpInstallError } = await import('./mcp-install-cmd-23ZY4IBK.js');
5948
+ const { runMcpInstall, handleMcpInstallError, McpInstallError } = await import('./mcp-install-cmd-SMPLT43Q.js');
5920
5949
  try {
5921
5950
  if (opts.transport !== void 0 && opts.transport !== "stdio" && opts.transport !== "http") {
5922
5951
  throw new McpInstallError(`--transport must be "stdio" or "http", got "${opts.transport}"`);
@@ -5938,7 +5967,7 @@ caller from the bearer token, the gateway answers 401 without that header.
5938
5967
  "after",
5939
5968
  "\nWhat the stdio .mcp.json entry spawns. Reads newline-delimited JSON-RPC 2.0 on\nstdin and writes responses on stdout. The API key comes from OUTERLAYER_API_KEY\nor ~/.outerlayer/config.json at start-up; with neither the command exits 1 and\nprints why, which the MCP client shows as the connect error.\n"
5940
5969
  ).action(async (opts) => {
5941
- const { runMcpServe, handleMcpServeError } = await import('./mcp-serve-cmd-ZINYSLY6.js');
5970
+ const { runMcpServe, handleMcpServeError } = await import('./mcp-serve-cmd-XXERT673.js');
5942
5971
  try {
5943
5972
  await runMcpServe({ url: opts.url, appId: opts.appId });
5944
5973
  } catch (err) {
@@ -5959,7 +5988,7 @@ would get, the instruction files and the names of the skills. It warns when the
5959
5988
  no \`build\`. It needs the context-read permission: a login or a factory key with it is enough.
5960
5989
  `
5961
5990
  ).action(async (opts) => {
5962
- const { runContextShow, ContextShowError } = await import('./context-show-cmd-MZ74ZIVO.js');
5991
+ const { runContextShow, ContextShowError } = await import('./context-show-cmd-4UXO5WQJ.js');
5963
5992
  try {
5964
5993
  const result = await runContextShow({ repo: opts.repo, json: opts.json, url: opts.url, apiKey: opts.apiKey, appId: opts.appId });
5965
5994
  process.stdout.write(result.output);