mulmoterminal 10.3.0 → 10.5.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (172) hide show
  1. package/README.md +35 -15
  2. package/bin/avatar-check.d.ts +3 -0
  3. package/bin/avatar-check.js +25 -0
  4. package/bin/mulmoterminal.js +3 -0
  5. package/bin/remotion-check.d.ts +1 -0
  6. package/bin/remotion-check.js +9 -4
  7. package/bin/update-check.js +6 -1
  8. package/common/endedCellClose.ts +26 -0
  9. package/common/fileChannel.ts +4 -0
  10. package/common/fileGrant.ts +24 -0
  11. package/common/keymap.ts +3 -3
  12. package/common/paneCommand.ts +4 -0
  13. package/dist/assets/{abnfDiagram-YUKMZFIV-DffHwWXp.js → abnfDiagram-WEYOIA3C-Ll8Tq6AV.js} +1 -1
  14. package/dist/assets/{architecture-WOLXFQ4H-B4GNOIk_.js → architecture-WOLXFQ4H-F2o7qqpo.js} +1 -1
  15. package/dist/assets/{architectureDiagram-47P4ROYG-D5vY2SMy.js → architectureDiagram-ZHVYKT53-DaboVwEe.js} +1 -1
  16. package/dist/assets/{blockDiagram-E7TT5TSB-gxkA84ZF.js → blockDiagram-RJAE7QA3-CGWn_g-c.js} +1 -1
  17. package/dist/assets/{c4Diagram-CRA5TL53-CngEYX2_.js → c4Diagram-XDPPPE54-BuP9UC59.js} +1 -1
  18. package/dist/assets/channel-B0OajmtD.js +1 -0
  19. package/dist/assets/{chunk-AW2ZBBNX-CwSnub2W.js → chunk-2E7WHVMD-Bo7YuQoV.js} +1 -1
  20. package/dist/assets/{chunk-HTAEGDNF-DxtDWkfP.js → chunk-4EMNKR2T-D8wywNvw.js} +1 -1
  21. package/dist/assets/{chunk-7TKQ45FW-DyUQ789M.js → chunk-55XCU76K-vGQ9DpDb.js} +1 -1
  22. package/dist/assets/{chunk-3YJQHVM4-pLkgFhom.js → chunk-7S6XSTFO-Dzp8lPeY.js} +1 -1
  23. package/dist/assets/{chunk-E2ZNV5FY-DJUXHUkG.js → chunk-AQDTSKZB-CFGL68LD.js} +1 -1
  24. package/dist/assets/{chunk-VPRB5NB3-B5_AFVkH.js → chunk-DSNLSHJZ-CEzOMBUc.js} +2 -2
  25. package/dist/assets/chunk-HAGFOTED-DyNvkM5y.js +62 -0
  26. package/dist/assets/chunk-HNE4Q36P-BnSZkit3.js +1 -0
  27. package/dist/assets/{chunk-EU5HNXII-BySfkmDB.js → chunk-NQOKRVIF-DH69Ts2R.js} +1 -1
  28. package/dist/assets/{chunk-4EA7E6EY-BlFEFaYB.js → chunk-UHW7PFBP-TIkE7nGG.js} +1 -1
  29. package/dist/assets/{chunk-KQW6MTUR-CrWUVuyL.js → chunk-VQ5W62QI-C2v_pZhZ.js} +1 -1
  30. package/dist/assets/chunk-WQQL4CDK-BfSxT8fr.js +10 -0
  31. package/dist/assets/{chunk-HJ2JQQFS-Digks1Bq.js → chunk-YZO67HFG-BXyqT0YR.js} +1 -1
  32. package/dist/assets/{chunk-DBDB3WZW-DS205Qyg.js → chunk-ZAUX2LTX-Disc29s0.js} +1 -1
  33. package/dist/assets/{chunk-FVRAUYC3-D1mJl1-O.js → chunk-ZCHMQSOR-B1NM7cOo.js} +1 -1
  34. package/dist/assets/{classDiagram-v2-K4WV4PDN-D_gx4H4g.js → classDiagram-v2-4MYWR3UA-Dz8IZJSz.js} +1 -1
  35. package/dist/assets/{cynefin-EF2NZ3EQ-DLm7x61k.js → cynefin-EF2NZ3EQ-CG9ZrOj-.js} +1 -1
  36. package/dist/assets/{cynefinDiagram-3GCD6N5R-D3u23291.js → cynefinDiagram-WF24UDRP-CPzYbm5j.js} +1 -1
  37. package/dist/assets/{dagre-W4DXFKR2-D6yfe3LF.js → dagre-NK4GIZVX-FthvuIgc.js} +1 -1
  38. package/dist/assets/{diagram-OVF4WLC6-JD_yzXTT.js → diagram-CBK3MWTC-_8CfeJGW.js} +1 -1
  39. package/dist/assets/{diagram-UMYRVEAY-C5pZm3XT.js → diagram-I5XIIV2D-vRgOi3de.js} +1 -1
  40. package/dist/assets/{diagram-PFPMY2P6-cGOmpWqw.js → diagram-ODIL2UCW-Db6re-y8.js} +1 -1
  41. package/dist/assets/{diagram-ZIFT7M5P-B8oLndAa.js → diagram-PFBEJUXE-B5soKDZ1.js} +1 -1
  42. package/dist/assets/{diagram-YEKJPTXX-De9PYt7f.js → diagram-RJA3I4VV-BOCJIA3i.js} +1 -1
  43. package/dist/assets/{diagram-2UJZ2QOL-giOHpm1j.js → diagram-TYUNFSNR-DHE509KX.js} +1 -1
  44. package/dist/assets/{dist-CFNmLHs1.js → dist-BhwfRHUZ.js} +1 -1
  45. package/dist/assets/{dist-BzGF_zMB.js → dist-CcRq66XZ.js} +1 -1
  46. package/dist/assets/{dist-BcMqPpIE.js → dist-D9Zv1PMa.js} +1 -1
  47. package/dist/assets/{dist-jOn8Bz45.js → dist-DbuQdU8b.js} +1 -1
  48. package/dist/assets/{dist-CcMtOolI.js → dist-Dn3sBVeP.js} +1 -1
  49. package/dist/assets/{ebnfDiagram-VR2GEFS7-jt9VmuSq.js → ebnfDiagram-V4P3TTPT-CKWGw4eq.js} +1 -1
  50. package/dist/assets/elk-QONTBCTQ-Dd-835hH.js +27 -0
  51. package/dist/assets/{erDiagram-O2IAPWRE-TWu5X3SA.js → erDiagram-KYQIGQAA-CDK17xNJ.js} +1 -1
  52. package/dist/assets/{eventmodeling-K75KTNOO-PtE5pg6R.js → eventmodeling-K75KTNOO-BW542wZb.js} +1 -1
  53. package/dist/assets/flowDiagram-IUGLLWBU-D7LlzDxp.js +1 -0
  54. package/dist/assets/{ganttDiagram-R7TSEDQI-C0vjJUP2.js → ganttDiagram-R7GPNTJY-CPFqLQbq.js} +1 -1
  55. package/dist/assets/{gitGraph-VSP46ZUC-DUnn2Ks0.js → gitGraph-VSP46ZUC-DSo0pTTR.js} +1 -1
  56. package/dist/assets/{gitGraphDiagram-XJZIOB7I-BV7GpNmB.js → gitGraphDiagram-PDYL7XHY-BH_YgYI9.js} +1 -1
  57. package/dist/assets/{index-DwFxX9SA.js → index-BGfm9wjj.js} +2132 -376
  58. package/dist/assets/{index-_LUAJpb4.css → index-BM7QNI7_.css} +1 -1
  59. package/dist/assets/{info-OHQRW6UA-DOdKJhVi.js → info-OHQRW6UA-Y2jOMp_q.js} +1 -1
  60. package/dist/assets/{infoDiagram-5W2HQ5XZ-KL8E_FFh.js → infoDiagram-MVDRKAX5-BaeTa6op.js} +1 -1
  61. package/dist/assets/{ishikawaDiagram-K3B6WC7H-v9e_wL9Y.js → ishikawaDiagram-HPEHV2GE-BTbbDH3h.js} +1 -1
  62. package/dist/assets/{journeyDiagram-COXZFDF6-V-bO2NO7.js → journeyDiagram-BOSHW7O7-TNk2cBxF.js} +1 -1
  63. package/dist/assets/{kanban-definition-P3RFRI5V-C1VMYlN0.js → kanban-definition-FNSA4HC5-QSGoV6OY.js} +1 -1
  64. package/dist/assets/katex-B940_AAO.js +257 -0
  65. package/dist/assets/{line-C0diT23N.js → line-Bs9za57d.js} +1 -1
  66. package/dist/assets/{manifold-CgYBP_Jl.js → manifold-Cng45y0-.js} +1 -1
  67. package/dist/assets/{marp-BantkFXR.js → marp-CWAfhmUo.js} +8 -8
  68. package/dist/assets/{mermaid-parser.core-CB6lGdQz.js → mermaid-parser.core-CdnPzxSk.js} +3 -3
  69. package/dist/assets/{mermaid.core-BKXyfrGA.js → mermaid.core-BVLO7qMH.js} +5 -5
  70. package/dist/assets/{mindmap-definition-LZFPQGKD-CwWeSOpr.js → mindmap-definition-6OY57UG3-DRWQIjeE.js} +11 -9
  71. package/dist/assets/{packet-JDAUHWVQ-3j2l_722.js → packet-JDAUHWVQ-BZOTrQNk.js} +1 -1
  72. package/dist/assets/{pegDiagram-BGZESJAR-CpUIaMK9.js → pegDiagram-ECIUJNBX-Dpwrv2z1.js} +1 -1
  73. package/dist/assets/{pie-XZMESJXO-CJWMFiuF.js → pie-XZMESJXO-D0EbxseJ.js} +1 -1
  74. package/dist/assets/{pieDiagram-CAPJLFHJ-C4Fp7dPt.js → pieDiagram-GNMPY74T-DRuZ06Db.js} +1 -1
  75. package/dist/assets/{quadrantDiagram-GDMTTRAM-C0ShPbme.js → quadrantDiagram-D57K4MC3-CKlpFVim.js} +1 -1
  76. package/dist/assets/{radar-ABXABTNO-DFP6iY8x.js → radar-ABXABTNO-CAc2PaQt.js} +1 -1
  77. package/dist/assets/{railroad-I3PHUGI6-DR6mwjNv.js → railroad-I3PHUGI6-Comi3RuA.js} +1 -1
  78. package/dist/assets/{railroad-abnf-LNEFI6M7-CO1T6T9c.js → railroad-abnf-LNEFI6M7-CtGDrthG.js} +1 -1
  79. package/dist/assets/{railroad-ebnf-DWYD2UWJ-Cpp3Whnh.js → railroad-ebnf-DWYD2UWJ-BnhGglff.js} +1 -1
  80. package/dist/assets/{railroad-peg-JR7BVNR7-SC6qrWHg.js → railroad-peg-JR7BVNR7-ClkVE9ii.js} +1 -1
  81. package/dist/assets/{railroadDiagram-SM67HX2B-D8arUcue.js → railroadDiagram-Y72NRBL7-ScBJj1FO.js} +1 -1
  82. package/dist/assets/{requirementDiagram-X7JNWC4A-BfuROELZ.js → requirementDiagram-EQYSW5RA-CRVIl6Q-.js} +1 -1
  83. package/dist/assets/{sankeyDiagram-UM26HJRW-Dx7qQKP3.js → sankeyDiagram-SY24JHO5-DFdiFLDW.js} +1 -1
  84. package/dist/assets/{sequenceDiagram-ZO4K6R2Y-BBZ2GElY.js → sequenceDiagram-BLEHNHQU-DQMDYLGK.js} +1 -1
  85. package/dist/assets/{stateDiagram-v2-TBUQTH76-Co9QstCS.js → stateDiagram-v2-A6IESKWZ-E-Am9Bi3.js} +1 -1
  86. package/dist/assets/swimlanes-B3ENRKFQ-AlvLqUC0.js +1 -0
  87. package/dist/assets/swimlanesDiagram-AYQRV4AK-DiOz2s_v.js +8 -0
  88. package/dist/assets/{timeline-definition-YOQAKGHF-CbNX3ELR.js → timeline-definition-JXYKGLGB-CmBedob5.js} +1 -1
  89. package/dist/assets/{treeView-D4JQ5SDB-a_Q9p0kF.js → treeView-D4JQ5SDB-Dhipj3ZB.js} +1 -1
  90. package/dist/assets/{treemap-SAJKECNS-CygMipNi.js → treemap-SAJKECNS-CjstBoW1.js} +1 -1
  91. package/dist/assets/{usecaseDiagram-VIAY4XPW-Cy66QR1P.js → usecaseDiagram-WPOLBNNX-CmfTl_Et.js} +1 -1
  92. package/dist/assets/{vennDiagram-BLWOH2XV-E5qHjzJo.js → vennDiagram-Q3Y3IDCW-C_AEIecK.js} +1 -1
  93. package/dist/assets/{wardley-7MLQ67FV-D9omOW8l.js → wardley-7MLQ67FV-RuDAm31w.js} +1 -1
  94. package/dist/assets/{wardleyDiagram-YMQ3BMBF-D7chXcuf.js → wardleyDiagram-IVAIDKWA-BHHEGzwz.js} +1 -1
  95. package/dist/assets/{xychartDiagram-TAQBALBS-BBAhbweQ.js → xychartDiagram-4URNHDU4-FnxylosZ.js} +1 -1
  96. package/dist/index.html +2 -2
  97. package/docs/ChangeLog.md +74 -0
  98. package/docs/facts.json +1 -1
  99. package/docs/guide/en/agents.md +4 -3
  100. package/docs/guide/en/basics.md +6 -5
  101. package/docs/guide/en/config.md +2 -2
  102. package/docs/guide/en/feature-list.md +10 -1
  103. package/docs/guide/en/features.md +3 -3
  104. package/docs/guide/en/glossary.md +1 -1
  105. package/docs/guide/en/header.md +3 -2
  106. package/docs/guide/en/index.md +2 -2
  107. package/docs/guide/en/mulmocast.md +86 -1
  108. package/docs/guide/en/pane-tools.md +3 -2
  109. package/docs/guide/en/v10.4.0.md +88 -0
  110. package/docs/guide/en/v10.5.0.md +128 -0
  111. package/docs/guide/ja/agents.md +4 -3
  112. package/docs/guide/ja/basics.md +3 -3
  113. package/docs/guide/ja/config.md +2 -2
  114. package/docs/guide/ja/feature-list.md +10 -1
  115. package/docs/guide/ja/features.md +2 -2
  116. package/docs/guide/ja/glossary.md +1 -1
  117. package/docs/guide/ja/header.md +3 -2
  118. package/docs/guide/ja/index.md +2 -2
  119. package/docs/guide/ja/mulmocast.md +79 -1
  120. package/docs/guide/ja/pane-tools.md +2 -1
  121. package/docs/guide/ja/v10.4.0.md +84 -0
  122. package/docs/guide/ja/v10.5.0.md +122 -0
  123. package/package.json +21 -21
  124. package/server/agents/antigravity/antigravity-config-file.ts +45 -0
  125. package/server/agents/antigravity/antigravity-hook.ts +62 -0
  126. package/server/agents/antigravity/antigravity-hooks-file.ts +62 -0
  127. package/server/agents/antigravity/antigravity-skills.ts +3 -19
  128. package/server/backends/boot-backends.ts +6 -2
  129. package/server/backends/files/fileChange.ts +16 -2
  130. package/server/backends/files/fileGrants.ts +95 -0
  131. package/server/backends/files/files.ts +2 -54
  132. package/server/backends/files/sendRawFile.ts +61 -0
  133. package/server/backends/plugins/mulmoscript.ts +27 -4
  134. package/server/backends/plugins/mulmoscriptWatch.ts +105 -0
  135. package/server/backends/plugins/mulmoscriptWatchRules.ts +39 -0
  136. package/server/config/env.ts +24 -0
  137. package/server/config/home-scope.ts +18 -0
  138. package/server/files/documentWatch.ts +19 -5
  139. package/server/infra/process/tmux.ts +6 -4
  140. package/server/infra/tools/pane-tools.ts +3 -2
  141. package/server/mcp/broker.ts +12 -3
  142. package/server/mcp/tool-gate.ts +31 -3
  143. package/server/routes/app-routes.ts +6 -0
  144. package/server/routes/hook-routes.ts +2 -0
  145. package/server/routes/mcp-routes.ts +59 -20
  146. package/server/routes/plugin-routes.ts +12 -5
  147. package/server/routes/tool-routes.ts +16 -3
  148. package/server/routes/ws-routes.ts +4 -0
  149. package/server/session/pty/agent-pty-start.ts +1 -1
  150. package/server/session/pty/pty-exit-log.ts +1 -3
  151. package/server/session/pty/pty-exit.ts +46 -11
  152. package/server/session/pty/pty-relay.ts +4 -5
  153. package/server/session/registry.ts +42 -2
  154. package/server/session/scheduled/background-chat.ts +23 -4
  155. package/server/session/session-drops.ts +3 -2
  156. package/server/session/spawn/agents/gui-group-restriction-log.ts +36 -0
  157. package/server/session/spawn/agents/spawn-antigravity.ts +7 -3
  158. package/server/session/spawn/agents/spawn-claude.ts +50 -20
  159. package/server/session/spawn/setup/mcp-config.ts +8 -0
  160. package/server/session/spawn/spawn-shell.ts +8 -7
  161. package/server/session/spawn/spawn-with-full-gui-claim.ts +6 -2
  162. package/server/session/types.ts +4 -0
  163. package/server/session/ws-frames.ts +13 -3
  164. package/dist/assets/channel-BowpOqgq.js +0 -1
  165. package/dist/assets/chunk-2BW5OAIV-C1ADF1k7.js +0 -10
  166. package/dist/assets/chunk-NTY3LDVX-Qm6Ijcog.js +0 -1
  167. package/dist/assets/chunk-XC4XBNZT-CdDLMW5_.js +0 -62
  168. package/dist/assets/elk-IJKZMXRS-BaUCO2zC.js +0 -27
  169. package/dist/assets/flowDiagram-OXPTDLAJ-DoaMFg6K.js +0 -1
  170. package/dist/assets/katex-DJhrJSbw.js +0 -257
  171. package/dist/assets/swimlanes-N4OXWK64-1fO2a_5p.js +0 -1
  172. package/dist/assets/swimlanesDiagram-K3J5GTZL-rJdkLNc6.js +0 -8
package/README.md CHANGED
@@ -168,7 +168,7 @@ copying from a web page usually does, so that pasting text keeps working.
168
168
 
169
169
  **Clicking a file path** — the other direction. A path an agent *prints* becomes a link, and
170
170
  **what it opens is chosen by its extension**, so each kind arrives as the thing it is rather
171
- than as bytes (files within the session's working directory only):
171
+ than as bytes:
172
172
 
173
173
  | A clicked … | opens as |
174
174
  |---|---|
@@ -180,22 +180,29 @@ than as bytes (files within the session's working directory only):
180
180
  | images, PDF, SVG, video, audio | raw bytes in a new tab, which the browser renders better than an editor would |
181
181
  | everything else — `.xlsx`, `.docx`, `.zip`, a `Makefile` | the app's own **Files** view. A tab cannot display these, so opening one there is not a view — it is a download starting with no warning. The pane names the file and offers **Open in OS**, which hands it to the application that owns it (Excel for an `.xlsx`) |
182
182
 
183
+ **A path outside the session's working directory opens too** — absolute, `~/…`, or `../` climbing out.
184
+ Markdown, JSON, tables and source open against the file's own directory. An HTML page, an image, a PDF,
185
+ an SVG, a video or an audio file opens in a new tab through a **one-file link**: the app asks the server
186
+ for it with a same-origin POST, and only that file is served under it — not its directory, and not the
187
+ image an HTML page links beside itself. The link lasts until the server restarts (or until many newer links push it out); seeking a video works.
188
+ A file that is not there says so in the tab.
189
+
183
190
  **A line after the path is followed.** `src/a.ts:42`, `src/a.ts:42:7` (gcc, clang, `eslint -f unix`,
184
191
  stack traces) and `src/a.ts(12,5)` (tsc) are one link. In the pane, and in the Files view, the file
185
192
  opens as text with the caret on that line and column — an HTML page, an SVG or a table included, and a
186
193
  tab reading in Preview switches to Edit. An image, a PDF, a video or an audio file has no line to go
187
194
  to and simply opens as itself. A route that renders the file in a new tab (`.md`, `.json`,
188
- `.csv`, `.html` with no cell enlarged) ignores the line. When the pane beside an enlarged cell takes
189
- the click, the keyboard stays in the terminal; the full-screen Files view, with no terminal beside it,
195
+ `.csv`, `.html` with no pane to take it) ignores the line. When the pane takes the click, the
196
+ keyboard stays in the terminal; the full-screen Files view, with no terminal beside it,
190
197
  puts it in the editor. (ESLint's default output puts the path on a line of its own, with no line number to follow.)
191
198
 
192
- **While a grid cell is enlarged, the [Files pane](#files-view-browse--edit) takes the click first** — every
199
+ **While a grid cell is enlarged, or a pane is open beside the tiled grid, the [Files pane](#files-view-browse--edit) takes the click first** — every
193
200
  row above, since the pane is the same editor with a Preview for Markdown, HTML and SVG, shows an
194
201
  image as a picture and a PDF in a frame, and plays a video or an audio file with the browser's own
195
202
  controls (seeking included, whatever the file's size). The file opens *beside* the terminal
196
203
  that printed it, and the pane opens itself if it was closed. It declines, leaving the routing
197
- above untouched, when nothing is enlarged, or when the path is not under that cell's own directory
198
- (the pane cannot walk above its root). A file too large to edit as text still offers **Open in OS**.
204
+ above untouched, when nothing is enlarged and no pane is beside the tiles, or when the path is not
205
+ under the directory of the cell the pane belongs to (the pane cannot walk above its root). A file too large to edit as text still offers **Open in OS**.
199
206
 
200
207
  Highlighting in the Files view covers the JS/TS family, JSON and Markdown (the modes
201
208
  `cmEditor.ts` bundles); other languages open as plain text.
@@ -356,7 +363,8 @@ for the details and model notes.
356
363
  A global install isn't auto-updated, so on startup MulmoTerminal checks npm and
357
364
  prints a one-line notice when a newer version is available — and the web toolbar shows a
358
365
  clickable **update badge** with the exact command for your install (`npm i -g mulmoterminal`,
359
- or `git pull` for a clone). The server repeats that check every few hours, so a release that
366
+ or `git pull origin main && yarn install && yarn build` for a clone, then restart — a pull alone
367
+ updates the server's code but leaves the dependencies and the browser's build as they were). The server repeats that check every few hours, so a release that
360
368
  ships while it is running still reaches the badge; the startup console notice is printed once
361
369
  and is not repeated. Disable with `MULMOTERMINAL_NO_UPDATE_CHECK=1` (or `NO_UPDATE_NOTIFIER=1`).
362
370
 
@@ -661,7 +669,9 @@ a tmux session, so **a server crash or restart doesn't kill your terminals** —
661
669
  processes keep running and reattach when the server comes back (like `screen`/`tmux`).
662
670
  A long build, a dev server, or a mid-turn Claude session all survive `node --watch`
663
671
  reloads and crashes. It uses its **own** tmux server (`-L mulmoterminal`) and config, so
664
- it never touches your personal tmux sessions or keybindings.
672
+ it never touches your personal tmux sessions or keybindings. A server started with `HOME`
673
+ pointed somewhere else gets a tmux server of its own (`mulmoterminal-<hash>`), so it never
674
+ sweeps or reconfigures the sessions of the one running on your real home.
665
675
 
666
676
  **And the server comes back by itself.** `npx mulmoterminal` supervises the server it
667
677
  started: a crash is restarted with a short backoff, so the browser tab reconnects to the
@@ -1326,7 +1336,10 @@ the same explorer + editor on the right, rooted at that cell's directory. Drag t
1326
1336
  (or focus it and use ←/→, Home, End) to resize — the terminal keeps a floor, so a squeeze
1327
1337
  shrinks the pane rather than reflowing xterm into garbage. It works in both zoomed layouts
1328
1338
  (cockpit roster and thumbnail filmstrip), the pane re-roots as you walk the zoom between
1329
- terminals, and whether it's open plus how wide it is are remembered per browser.
1339
+ terminals, and whether it's open plus how wide it is are remembered per browser. Without
1340
+ enlarging anything, a tile's **History** / **Tools** menu (or *Browse files in the app*) opens
1341
+ the same pane to the right of the tiled grid; it stays on that tile until another tile's menu
1342
+ asks for it, and only an enlarged cell's pane can take the full width.
1330
1343
 
1331
1344
  **Coming back looks the way you left it.** The pane remembers the open file, the directories
1332
1345
  you had expanded, and — for a file with a Preview — whether you were reading it in **Preview** or
@@ -1389,8 +1402,8 @@ goes to the tab that file already has. A link that climbs above the pane's folde
1389
1402
  the pane says so; an external link opens in a new browser tab, and a `#heading` link scrolls the
1390
1403
  document.
1391
1404
 
1392
- The toggle is not the only way in: while a cell is enlarged, **clicking a file path the agent
1393
- printed** opens it here too, rather than in a new tab or full-screen — see
1405
+ The toggle is not the only way in: while a cell is enlarged, or this pane is open beside the tiled
1406
+ grid, **clicking a file path the agent printed** opens it here too, rather than in a new tab or full-screen — see
1394
1407
  [Clicking a file path](#clicking-a-file-path).
1395
1408
 
1396
1409
  **Open a file by name instead of walking the tree.** The pane's header has a **search** button
@@ -1834,7 +1847,7 @@ narrow and tall for one record you are discussing — and each position keeps it
1834
1847
  isn't available yet (Codex writes its rollout only once the turn ends).
1835
1848
  - **Tools pane** (the cell header's **Tools** menu, beside the Canvas, Collections and **Restart the agent**) — the available GUI tools plus a live tool-call history for the active
1836
1849
  session.
1837
- - **Prompts pane** — the prompts *you* sent the enlarged cell's session, newest first, from
1850
+ - **Prompts pane** — the prompts *you* sent that cell's session, newest first, from
1838
1851
  `GET /api/transcript/prompts`. The mirror of the Timeline above: that one is what the agent
1839
1852
  ran, this one is what you asked it for — for when several cells are running and you can no
1840
1853
  longer remember which one you told what. Read-only; click a long prompt to open it in place.
@@ -1842,7 +1855,7 @@ narrow and tall for one record you are discussing — and each position keeps it
1842
1855
  prompt history, codex's rollout), so a prompt sent mid-turn is there and text a skill
1843
1856
  injected is not. A `/clear` draws a line: the pane shows what you have asked *since*, the
1844
1857
  same way the header, the title and the last reply all stop describing the ended conversation.
1845
- - **Conversation pane** — the enlarged cell's conversation, read as TURNS rather than as the
1858
+ - **Conversation pane** — that cell's conversation, read as TURNS rather than as the
1846
1859
  screen, from `GET /api/transcript/view`. A Claude cell runs on the alternate screen, so the
1847
1860
  terminal keeps no scrollback worth scrolling; this reads the agent's own transcript instead,
1848
1861
  and **scrolling up walks the session back to its first turn**, a page at a time.
@@ -2124,7 +2137,7 @@ From a shell: `mulmoterminal room read <room>` · `room post <room> <text…> [-
2124
2137
  | Endpoint | Purpose |
2125
2138
  | -------- | ------- |
2126
2139
  | `POST /api/mcp/:sessionId` | Per-session GUI MCP server (Streamable HTTP; `GET`/`DELETE` → 405). |
2127
- | `POST /api/plugin/:toolName` | GUI-plugin dispatch (incl. `spawnBackgroundChat`, `manageAccounting`, `presentHtml`). |
2140
+ | `POST /api/plugin/:toolName` | GUI-plugin dispatch (incl. `spawnBackgroundChat`, `manageAccounting`, `presentHtml`). `spawnBackgroundChat` takes an optional `guiGroups` (claude only): a list of tool groups (`render`, `data`, `media`, `external`) the spawned session is limited to, `[]` for no GUI tool. The limit holds across a resume. It is not a sandbox: the tools stay callable over HTTP. |
2128
2141
  | `GET /api/agent/toolResults/:id` · `POST /api/agent/toolResult` | GUI-panel result history / persist. |
2129
2142
  | `GET /api/tools` · `GET /api/tool-calls/:id` | Available tools / tool-call history. |
2130
2143
  | `POST /api/accounting` | Double-entry accounting (bundled plugin). |
@@ -2174,7 +2187,7 @@ connection (or reattach to an existing background PTY).
2174
2187
  | ------- | ------- |
2175
2188
  | `{ "type": "session", "id": string }` | Sent immediately on connect — the session id this socket is bound to (lets the client learn a new session's generated id). |
2176
2189
  | `{ "type": "output", "data": string }` | PTY output to write to the terminal. On reattach, the first `output` frame is the replayed tail buffer (≤ 64 KB). |
2177
- | `{ "type": "exit", "exitCode": number, "signal": number }` | The `claude` process exited; the socket then closes. |
2190
+ | `{ "type": "exit", "exitCode": number, "signal": number, "lifetimeMs": number, "reattached": boolean, "ended": boolean }` | The pty exited; the socket then closes. `ended` is true only when the SESSION ended (tmux closed with the program) — a tmux client killed from outside, or an exit after an explicit close or restart, sends `false`. Under tmux `exitCode` is the client's and reads `0` even when the program failed. `lifetimeMs` is this pty's, which on a reattach (`reattached: true`) is not the program's. An agent cell closes itself on `ended` unless the program died while starting. The three newer fields are additive; a client treats their absence as "not ended". |
2178
2191
  | `{ "type": "paneMode", "inCopyMode": boolean }` | tmux-backed sessions only: whether the pane is in tmux copy-mode, where keys go to tmux instead of the program. Sent when it changes, and again to a reattached socket. |
2179
2192
 
2180
2193
  **Client → server** (JSON text frames):
@@ -2320,6 +2333,13 @@ Key rules:
2320
2333
  offering to take it over — and the server answers "anywhere" from its own PTY
2321
2334
  table plus tmux, so another browser tab and a second `mulmoterminal` process
2322
2335
  count too.
2336
+ - **An agent that ends on its own takes its cell with it.** `/exit`, Ctrl+C or a crash
2337
+ closes the cell as the close button would, so it is in the palette's **Reopen** list
2338
+ and resumes the conversation. Three cases keep the `[session ended]` banner instead:
2339
+ an agent that died while still starting up (a launch failure — under tmux its
2340
+ exit code reads 0, so the banner is the only evidence), a tmux client killed from
2341
+ outside while the agent still runs, and a worktree cell (its close asks whether to
2342
+ keep the worktree).
2323
2343
  - Brand-new sessions are listed **immediately** (before their `.jsonl`
2324
2344
  exists) via the in-memory `knownSessions` registry + a `created` push; an
2325
2345
  unused one disappears when its PTY is reaped.
@@ -0,0 +1,3 @@
1
+ export declare const AVATAR_PACKAGES: readonly string[];
2
+ export declare function avatarCheckLine(missing: readonly string[]): string;
3
+ export declare function avatarCheck(pkgDir: string): string | null;
@@ -0,0 +1,25 @@
1
+ // Whether mulmocast can render a talking avatar on this machine. Like Remotion's, its packages are
2
+ // optional peers of mulmocast that a user installs only to use them — into ~/node_modules, since an
3
+ // npx entry is replaced on every release — so they are looked for from mulmocast's own location.
4
+
5
+ import { missingRemotionPackages, optionalPackagesLine, resolverFromMulmocast } from "./remotion-check.js";
6
+
7
+ /** What an avatar needs, as mulmocast's own install hint names it (it exports no list of its own). */
8
+ export const AVATAR_PACKAGES = ["avatarscript", "onnxruntime-node"];
9
+
10
+ const AVATAR = {
11
+ label: "avatar",
12
+ why: "talking avatars in MulmoCast videos",
13
+ guideUrl: "https://receptron.github.io/mulmoterminal/guide/en/mulmocast.html#avatar",
14
+ };
15
+
16
+ export function avatarCheckLine(missing) {
17
+ return optionalPackagesLine(AVATAR, missing, AVATAR_PACKAGES.length);
18
+ }
19
+
20
+ /** The `init` line for avatars, or null when mulmocast cannot be found. */
21
+ export function avatarCheck(pkgDir) {
22
+ const isResolvable = resolverFromMulmocast(pkgDir);
23
+ if (!isResolvable) return null;
24
+ return avatarCheckLine(missingRemotionPackages(AVATAR_PACKAGES, isResolvable));
25
+ }
@@ -15,6 +15,7 @@ import { fileURLToPath } from "node:url";
15
15
  import { computeUpdateNotice, isUpdateCheckDisabled } from "./update-check.js";
16
16
  import { detectNpxCacheDir, npxCacheHintLines } from "./npx-cache-hint.js";
17
17
  import { remotionCheck } from "./remotion-check.js";
18
+ import { avatarCheck } from "./avatar-check.js";
18
19
  import { configuredRemoteServer, sshTunnelHintLines } from "./ssh-hint.js";
19
20
  import { planAfterServerExit } from "./server-supervision.js";
20
21
  import { waitUntilReady } from "./wait-ready.js";
@@ -257,6 +258,8 @@ async function runInit(initArgs) {
257
258
  [...PATH_TOOLS, fileDialogTool()].filter(Boolean).forEach((tool) => console.log(toolCheckLine(tool)));
258
259
  const remotionLine = await remotionCheck(PKG_DIR);
259
260
  if (remotionLine) console.log(remotionLine);
261
+ const avatarLine = avatarCheck(PKG_DIR);
262
+ if (avatarLine) console.log(avatarLine);
260
263
 
261
264
  // Config half: derive working-dir presets from Claude history + write config.json.
262
265
  console.log("");
@@ -1,5 +1,6 @@
1
1
  export declare function resolverFromMulmocast(pkgDir: string): ((name: string) => boolean) | null;
2
2
  export declare function remotionPackagesFromMulmocast(pkgDir: string): Promise<readonly string[] | null>;
3
3
  export declare function missingRemotionPackages(packages: readonly string[], isResolvable: (name: string) => boolean): string[];
4
+ export declare function optionalPackagesLine(what: { label: string; why: string; guideUrl: string }, missing: readonly string[], total: number): string;
4
5
  export declare function remotionCheckLine(missing: readonly string[], total: number): string;
5
6
  export declare function remotionCheck(pkgDir: string): Promise<string | null>;
@@ -45,11 +45,16 @@ export function missingRemotionPackages(packages, isResolvable) {
45
45
  return packages.filter((name) => !isResolvable(name));
46
46
  }
47
47
 
48
- export function remotionCheckLine(missing, total) {
49
- if (missing.length === 0) return ` ✓ remotion — ${WHY}`;
48
+ /** The `init` line for a set of optional packages: passing, absent, or installed only in part. */
49
+ export function optionalPackagesLine({ label, why, guideUrl }, missing, total) {
50
+ if (missing.length === 0) return ` ✓ ${label} — ${why}`;
50
51
  const head =
51
- missing.length === total ? ` ○ remotion — optional (${WHY})` : ` ○ remotion — optional (${WHY}), installed only in part; missing: ${missing.join(", ")}`;
52
- return `${head}\n → ${GUIDE_URL}`;
52
+ missing.length === total ? ` ○ ${label} — optional (${why})` : ` ○ ${label} — optional (${why}), installed only in part; missing: ${missing.join(", ")}`;
53
+ return `${head}\n → ${guideUrl}`;
54
+ }
55
+
56
+ export function remotionCheckLine(missing, total) {
57
+ return optionalPackagesLine({ label: "remotion", why: WHY, guideUrl: GUIDE_URL }, missing, total);
53
58
  }
54
59
 
55
60
  /** The `init` line for remotion, or null when mulmocast cannot be asked. */
@@ -154,11 +154,16 @@ export function isSafeBranchName(name) {
154
154
  // and equal shas mean it is already current. Only a clean checkout whose HEAD
155
155
  // differs from the remote's is behind — count is deliberately absent, since
156
156
  // counting commits needs the objects a `git fetch` would bring and we skip it.
157
+ // A pull alone updates the server's code and nothing else: the dependencies and the browser's
158
+ // build stay as they were, and this notice clears anyway, so the command carries both steps. The
159
+ // restart is said before "run: " because what follows it is the part the badge copies.
160
+ const AFTER_PULL = "yarn install && yarn build";
161
+
157
162
  export function gitUpdateNotice({ localSha, localShort, remoteSha, defaultBranch, dirty }) {
158
163
  if (dirty) return null;
159
164
  if (!localSha || !remoteSha || localSha === remoteSha) return null;
160
165
  const pull = isSafeBranchName(defaultBranch) ? `git pull origin ${defaultBranch}` : "git pull";
161
- return `Update available: ${localShort || localSha.slice(0, 7)} → origin · run: ${pull}`;
166
+ return `Update available: ${localShort || localSha.slice(0, 7)} → origin (restart after updating) · run: ${pull} && ${AFTER_PULL}`;
162
167
  }
163
168
 
164
169
  // ls-remote reaches the network (an SSH/HTTPS handshake to the origin host), so it routinely
@@ -0,0 +1,26 @@
1
+ // When an agent cell closes itself because its session ended (#3049). Shared because the server
2
+ // measures the startup window for its exit log and the browser decides the close from the same one.
3
+
4
+ // Under this, an exit is a failure to start rather than an ending. Claude Code takes ~1.5s to
5
+ // draw its first frame here, so anything inside this window is a process that never got going.
6
+ export const STARTUP_WINDOW_MS = 2000;
7
+
8
+ export interface EndedCellExit {
9
+ /** The server reaped the session — not merely lost the tmux client, which leaves the agent running. */
10
+ sessionEnded: boolean;
11
+ /** How long the pty lived, or null when the frame named none. Under tmux the exit code is the
12
+ * client's and reads 0 even for an agent that failed to start, so the lifetime is what is left
13
+ * to tell a launch failure, whose banner must stay readable, from an agent that was ended. */
14
+ lifetimeMs: number | null;
15
+ /** The pty attached to an agent that was already running, so its lifetime is not the agent's
16
+ * and an exit soon after the attach is an ending, not a launch failure. */
17
+ reattached: boolean;
18
+ /** A worktree cell's close asks whether to keep the worktree; that is not asked unprompted. */
19
+ worktreeCell: boolean;
20
+ }
21
+
22
+ export function shouldCloseEndedCell(exit: EndedCellExit): boolean {
23
+ if (!exit.sessionEnded || exit.worktreeCell) return false;
24
+ if (exit.reattached) return true;
25
+ return exit.lifetimeMs !== null && exit.lifetimeMs >= STARTUP_WINDOW_MS;
26
+ }
@@ -14,6 +14,10 @@ const PATH_MARKER = ":file:";
14
14
  /** The scope the markdown plugin's View and the server's markdown matcher agree on. */
15
15
  export const MARKDOWN_FILE_SCOPE = "markdown";
16
16
 
17
+ /** The mulmoScript plugin's scope: its View's runtime channels (`plugin:mulmoScript:<event>`), and
18
+ * the one-file channel the Files pane subscribes to so the server watches an open story (#3014). */
19
+ export const MULMOSCRIPT_SCOPE = "mulmoScript";
20
+
17
21
  /** The channel one file is announced on, under one plugin scope. */
18
22
  export function pluginFileChannel(scope: string, posixPath: string): string {
19
23
  return `${CHANNEL_PREFIX}${scope}${PATH_MARKER}${posixPath}`;
@@ -0,0 +1,24 @@
1
+ // A file outside every directory the server already serves, opened in a tab by a click (#3024).
2
+ // The raw route refuses such a file, because a cross-site page could embed it; instead the app asks
3
+ // for a one-file URL with a same-origin POST, and only that file is served under it. Both sides
4
+ // decide from these: the browser which clicks go this way, the server which files it will grant.
5
+ import { HTML_FILE_NAME } from "./filesPage.js";
6
+ import { rawContentType } from "./rawContentType.js";
7
+
8
+ export const FILE_GRANT_ROUTE = "/api/files/grant";
9
+ export const GRANTED_FILE_ROUTE = "/api/files/granted";
10
+
11
+ /** How a granted file is sent: an HTML page under the preview CSP, anything else as the raw route
12
+ * sends it. Null for a type a tab would not show, which keeps going where it went before. */
13
+ export type GrantKind = "page" | "raw";
14
+
15
+ const SHOWN_RAW = /^(image|video|audio)\/|^application\/pdf$/;
16
+
17
+ export function grantKind(name: string): GrantKind | null {
18
+ if (HTML_FILE_NAME.test(name)) return "page";
19
+ return SHOWN_RAW.test(rawContentType(name)) ? "raw" : null;
20
+ }
21
+
22
+ /** The POST's answer: the URL to open, or why there is none. `missing` is its own reason so the tab
23
+ * can say the file is not there, rather than that it was refused. */
24
+ export type FileGrantResult = { ok: true; url: string } | { ok: false; reason: "missing" | "refused" };
package/common/keymap.ts CHANGED
@@ -98,9 +98,9 @@ export const TERMINAL_SCOPED_ACTIONS: readonly KeymapAction[] = ["copy", "paste"
98
98
  // Here rather than beside gridShortcutFor because BOTH sides decide from it: the grid dispatches on
99
99
  // it, and validateKeymap has to know that these decline the key — the handler returns WITHOUT
100
100
  // stopping the event, so a `send` on the same keystroke fires instead (codex on #1906).
101
- // `files-find` and `files-search` are here because the pane they open exists only in the ENLARGED
102
- // row (see docs/grid-view-modes.md) — a tiled grid has nowhere to put it, so the key declines
103
- // rather than guessing which of nine terminals was meant.
101
+ // `files-find` and `files-search` are here because the key names no cell: a pane CAN sit beside the
102
+ // tiled grid (docs/grid-view-modes.md), but only one a tile's menu opened, so un-zoomed the key
103
+ // declines rather than guessing which of nine terminals was meant.
104
104
  export const NEEDS_A_CURRENT_TERMINAL: readonly KeymapAction[] = [
105
105
  "zoom-next",
106
106
  "zoom-prev",
@@ -127,3 +127,7 @@ export function checkSummary(check: Pick<PaneCheck, "title" | "items">, answers:
127
127
  const head = `Check results for "${oneLine(check.title)}" (${tally}):`;
128
128
  return [head, ...lines].join(" ");
129
129
  }
130
+
131
+ /** Typed in when the user puts the card away unanswered, so an agent told to wait for the results is
132
+ * not left waiting for a message that will never come. */
133
+ export const checkClosedNotice = (check: Pick<PaneCheck, "title">): string => `Check "${oneLine(check.title)}" was closed without answers.`;
@@ -1 +1 @@
1
- import{m as e,t}from"./mermaid-parser.core-CB6lGdQz.js";import{n}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{m as r}from"./src-JH1jZ6Eh.js";import"./chunk-VPRB5NB3-B5_AFVkH.js";import{n as i,r as a,t as o}from"./chunk-AW2ZBBNX-CwSnub2W.js";import{t as s}from"./chunk-JWPE2WC7-DVXcaiue.js";import"./mermaid.core-BKXyfrGA.js";var c=e().RailroadAbnf.parser.LangiumParser,l=n(e=>{let t=e.alternatives.map(u);return t.length===1?t[0]:{type:`choice`,alternatives:t}},`transformAlternation`),u=n(e=>{let t=e.elements.map(f);return t.length===1?t[0]:{type:`sequence`,elements:t}},`transformConcatenation`),d=n(e=>{if(e.includes(`*`)){let[t,n]=e.split(`*`);return{min:t?parseInt(t,10):0,max:n?parseInt(n,10):1/0}}let t=parseInt(e,10);return{min:t,max:t}},`parseRepeat`),f=n(e=>{let t=p(e.primary);if(!e.repeat)return t;let{min:n,max:r}=d(e.repeat);return n===0&&r===1?{type:`optional`,element:t}:{type:`repetition`,element:t,min:n,max:r}},`transformElement`),p=n(e=>{switch(e.$type){case`AbnfStringLiteral`:return{type:`terminal`,value:e.value};case`AbnfNumVal`:return{type:`terminal`,value:e.value};case`AbnfRuleName`:return{type:`nonterminal`,name:e.name};case`AbnfGroup`:return l(e.element);case`AbnfOptionalGroup`:return{type:`optional`,element:l(e.element)};default:throw Error(`Unsupported ABNF primary node: ${e.$type}`)}},`transformPrimary`),m=n(e=>({name:e.name,definition:l(e.definition)}),`transformRule`),h=n(e=>{s(e,o),e.title&&o.setTitle(e.title),e.rules.map(e=>o.addRule(m(e)))},`populateDb`),g={parser:{parse:n(e=>{o.clear(),r.debug(`[ABNF Parser] Starting Langium parse`);let n=c.parse(e);if(n.lexerErrors.length>0||n.parserErrors.length>0)throw new t(n);let i=n.value;r.debug(`[ABNF Parser] Parsed rules:`,i.rules.length),h(i),r.debug(`[ABNF Parser] Parse complete`)},`parse`),parser:{yy:o}},db:o,renderer:a,styles:i};export{g as diagram};
1
+ import{m as e,t}from"./mermaid-parser.core-CdnPzxSk.js";import{n}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{m as r}from"./src-JH1jZ6Eh.js";import"./chunk-DSNLSHJZ-CEzOMBUc.js";import{n as i,r as a,t as o}from"./chunk-2E7WHVMD-Bo7YuQoV.js";import{t as s}from"./chunk-JWPE2WC7-DVXcaiue.js";import"./mermaid.core-BVLO7qMH.js";var c=e().RailroadAbnf.parser.LangiumParser,l=n(e=>{let t=e.alternatives.map(u);return t.length===1?t[0]:{type:`choice`,alternatives:t}},`transformAlternation`),u=n(e=>{let t=e.elements.map(f);return t.length===1?t[0]:{type:`sequence`,elements:t}},`transformConcatenation`),d=n(e=>{if(e.includes(`*`)){let[t,n]=e.split(`*`);return{min:t?parseInt(t,10):0,max:n?parseInt(n,10):1/0}}let t=parseInt(e,10);return{min:t,max:t}},`parseRepeat`),f=n(e=>{let t=p(e.primary);if(!e.repeat)return t;let{min:n,max:r}=d(e.repeat);return n===0&&r===1?{type:`optional`,element:t}:{type:`repetition`,element:t,min:n,max:r}},`transformElement`),p=n(e=>{switch(e.$type){case`AbnfStringLiteral`:return{type:`terminal`,value:e.value};case`AbnfNumVal`:return{type:`terminal`,value:e.value};case`AbnfRuleName`:return{type:`nonterminal`,name:e.name};case`AbnfGroup`:return l(e.element);case`AbnfOptionalGroup`:return{type:`optional`,element:l(e.element)};default:throw Error(`Unsupported ABNF primary node: ${e.$type}`)}},`transformPrimary`),m=n(e=>({name:e.name,definition:l(e.definition)}),`transformRule`),h=n(e=>{s(e,o),e.title&&o.setTitle(e.title),e.rules.map(e=>o.addRule(m(e)))},`populateDb`),g={parser:{parse:n(e=>{o.clear(),r.debug(`[ABNF Parser] Starting Langium parse`);let n=c.parse(e);if(n.lexerErrors.length>0||n.parserErrors.length>0)throw new t(n);let i=n.value;r.debug(`[ABNF Parser] Parsed rules:`,i.rules.length),h(i),r.debug(`[ABNF Parser] Parse complete`)},`parse`),parser:{yy:o}},db:o,renderer:a,styles:i};export{g as diagram};
@@ -1 +1 @@
1
- import"./chunk-NGNAAXSQ-C2Wy9Xmz.js";export{M as createArchitectureServices}from"./mermaid-parser.core-CB6lGdQz.js";
1
+ import"./chunk-NGNAAXSQ-C2Wy9Xmz.js";export{M as createArchitectureServices}from"./mermaid-parser.core-CdnPzxSk.js";