rvlib-shipkit 2.31.0 → 2.32.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 (384) hide show
  1. package/CHANGELOG.md +31 -0
  2. package/package.json +1 -1
  3. package/src/advisors/acts.ts +16 -15
  4. package/src/advisors/advice.ts +56 -102
  5. package/src/advisors/advisor-view.ts +98 -73
  6. package/src/advisors/app-graph.ts +1 -1
  7. package/src/advisors/app.ts +3 -11
  8. package/src/advisors/cf-api.ts +1 -1
  9. package/src/advisors/dir-bucket.ts +4 -3
  10. package/src/advisors/edge/api.ts +26 -198
  11. package/src/advisors/edge/bucket.ts +2 -2
  12. package/src/advisors/edge/handler.ts +13 -155
  13. package/src/advisors/edge/here.ts +5 -5
  14. package/src/advisors/edge/pages.ts +12 -9
  15. package/src/advisors/edge/shell.ts +6 -5
  16. package/src/advisors/edge/sign-in.ts +101 -36
  17. package/src/advisors/edge/status.ts +19 -6
  18. package/src/advisors/edge/types.ts +36 -60
  19. package/src/advisors/expose.ts +29 -29
  20. package/src/advisors/here.ts +12 -12
  21. package/src/advisors/invite-send.ts +79 -35
  22. package/src/advisors/invite.ts +31 -8
  23. package/src/advisors/job.ts +24 -16
  24. package/src/advisors/login.ts +40 -15
  25. package/src/advisors/owner-store.ts +46 -22
  26. package/src/advisors/photos.ts +3 -3
  27. package/src/advisors/project.ts +25 -23
  28. package/src/advisors/reach.ts +89 -0
  29. package/src/advisors/rights.ts +1 -1
  30. package/src/advisors/routes.ts +55 -74
  31. package/src/advisors/scan.ts +0 -4
  32. package/src/advisors/setup-run.ts +14 -14
  33. package/src/advisors/share-trace.ts +3 -3
  34. package/src/advisors/{door-probe.ts → sign-in-probe.ts} +7 -6
  35. package/src/advisors/speaks.ts +29 -0
  36. package/src/advisors/sync.ts +92 -182
  37. package/src/advisors/tunnel.ts +6 -5
  38. package/src/advisors/users-listen.ts +92 -0
  39. package/src/advisors/users-router.ts +257 -85
  40. package/src/advisors/users-store.ts +81 -0
  41. package/src/agent-time/blocked-scan.ts +181 -0
  42. package/src/agent-time/registry.ts +12 -5
  43. package/src/agent-time/store.ts +9 -109
  44. package/src/asks/ask-bar-fold.ts +2 -1
  45. package/src/asks/ask-close.ts +2 -1
  46. package/src/asks/ask-doc.ts +2 -1
  47. package/src/asks/ask-migrate.ts +3 -2
  48. package/src/asks/ask-steps-fold.ts +2 -1
  49. package/src/asks/ask-store.ts +4 -3
  50. package/src/check.ts +3 -43
  51. package/src/checks/SK001-package-json-shape.check.ts +4 -55
  52. package/src/checks/SK004-gitignore-policy.check.ts +24 -69
  53. package/src/checks/SK013-one-way-in-policy.check.ts +3 -7
  54. package/src/checks/SK017-vscode-hub-task.check.ts +4 -4
  55. package/src/checks/SK019-tests-run-in-units.check.ts +3 -14
  56. package/src/checks/SK020-self-spawning-check.check.ts +5 -7
  57. package/src/checks/SK035-public-clean.check.ts +1 -1
  58. package/src/checks/SK039-vscode-watch-generated.check.ts +1 -1
  59. package/src/checks/SK042-post-kinds.check.ts +5 -14
  60. package/src/checks/SK054-agent-allow-list.check.ts +5 -74
  61. package/src/checks/SK055-retired-config-keys.check.ts +45 -0
  62. package/src/cli/cmd_Advisors.ts +11 -45
  63. package/src/cli/cmd_Asks.ts +3 -10
  64. package/src/cli/cmd_Backup.ts +25 -127
  65. package/src/cli/cmd_BackupTargets.ts +1 -1
  66. package/src/cli/cmd_Checks.ts +0 -14
  67. package/src/cli/cmd_Db.ts +3 -82
  68. package/src/cli/cmd_Home.ts +4 -32
  69. package/src/cli/cmd_Hq.ts +0 -17
  70. package/src/cli/cmd_Releases.ts +57 -4
  71. package/src/cli/cmd_Review.ts +333 -354
  72. package/src/cli/cmd_SocialDrafts.ts +6 -13
  73. package/src/cli/cmd_ThreadSyncNeeds.ts +6 -2
  74. package/src/cli/cmd_Time.ts +1 -1
  75. package/src/cli/cmd_Trailer.ts +1 -1
  76. package/src/cli/inbox-hook-run.ts +5 -23
  77. package/src/cli/registry-heads.ts +5 -55
  78. package/src/cli/registry.ts +1 -5
  79. package/src/cli/review-here.ts +1 -1
  80. package/src/cli.ts +2 -2
  81. package/src/collections/collection-types.ts +1 -1
  82. package/src/collections/review.ts +5 -4
  83. package/src/core/agent-allow-policy.ts +32 -2
  84. package/src/core/agent-env.ts +8 -0
  85. package/src/core/allow-rows.ts +74 -0
  86. package/src/core/check-file-names.ts +19 -106
  87. package/src/core/footprint.ts +17 -13
  88. package/src/core/identities-root.ts +1 -4
  89. package/src/core/layout.ts +1 -2
  90. package/src/core/machine-db.ts +33 -208
  91. package/src/core/machine-layout.ts +14 -127
  92. package/src/core/mask-source.ts +60 -0
  93. package/src/core/memory-watch.ts +17 -14
  94. package/src/core/motherhome.ts +8 -35
  95. package/src/core/one-way-in-policy.ts +0 -3
  96. package/src/core/repo-walk.ts +0 -9
  97. package/src/core/retention.ts +1 -9
  98. package/src/core/retired-checks.ts +2 -0
  99. package/src/core/tmux-policy.ts +1 -1
  100. package/src/core/tree-watch.ts +2 -2
  101. package/src/core/when.ts +7 -45
  102. package/src/gate/discover-checks.ts +42 -32
  103. package/src/gate/gate-checks.ts +21 -131
  104. package/src/gate/pre-commit-discovery.ts +16 -25
  105. package/src/gate/run-check.ts +0 -4
  106. package/src/gate/run-fix.ts +5 -17
  107. package/src/gate/run-fixers.ts +6 -42
  108. package/src/home/app-sign.ts +2 -2
  109. package/src/home/backup-status.ts +52 -92
  110. package/src/home/backup-verdict.ts +2 -2
  111. package/src/home/daemon-jobs.ts +51 -95
  112. package/src/home/database-words.ts +1 -2
  113. package/src/home/databases.ts +9 -25
  114. package/src/home/home-launchd.ts +0 -6
  115. package/src/home/home-paths.ts +8 -4
  116. package/src/home/home-routes.ts +3 -10
  117. package/src/home/home-state.ts +2 -14
  118. package/src/home/inbox-shape.ts +14 -15
  119. package/src/home/inbox.ts +1 -1
  120. package/src/home/machine-repair.ts +102 -103
  121. package/src/home/resume.ts +1 -15
  122. package/src/home/run-daemon.ts +4 -11
  123. package/src/home/space-page.ts +3 -2
  124. package/src/home/supervise.ts +3 -7
  125. package/src/hooks/hook-config.ts +6 -7
  126. package/src/hooks/leak-guard.ts +1 -1
  127. package/src/hooks/run-hooks.ts +0 -5
  128. package/src/hq/daemon-db.ts +8 -8
  129. package/src/hq/door.ts +3 -16
  130. package/src/hq/hq-db.ts +4 -3
  131. package/src/hq/hq-local.ts +1 -2
  132. package/src/hq/hq-store.ts +0 -15
  133. package/src/hq/item-direct.ts +8 -10
  134. package/src/hq/item-fill.ts +37 -0
  135. package/src/hq/kinds/item-gone.ts +7 -10
  136. package/src/hq/kinds/item-msg.ts +12 -18
  137. package/src/hq/kinds/item.ts +13 -19
  138. package/src/hq/kinds/report.ts +3 -4
  139. package/src/hq/owner-switch.ts +3 -3
  140. package/src/hq/report.ts +5 -9
  141. package/src/hq/switch.ts +2 -11
  142. package/src/hq/thread-sync.ts +5 -17
  143. package/src/hq/{shapes-words.ts → threads-words.ts} +2 -12
  144. package/src/http/owner-word.ts +1 -1
  145. package/src/identities/machine.ts +16 -0
  146. package/src/init-repo.ts +0 -1
  147. package/src/ledger/check-stats.ts +6 -5
  148. package/src/ledger/db.ts +2 -4
  149. package/src/ledger/record-kept.ts +117 -48
  150. package/src/ledger/run-log.ts +21 -2
  151. package/src/ledger/slow-tests.ts +96 -0
  152. package/src/ledger/store.ts +3 -86
  153. package/src/ledger/suite-log.ts +8 -2
  154. package/src/media-store/backup/facts.ts +3 -37
  155. package/src/media-store/backup/keys.ts +1 -8
  156. package/src/media-store/backup/manifest.ts +6 -67
  157. package/src/media-store/backup/restore.ts +4 -13
  158. package/src/media-store/backup/retention.ts +13 -1
  159. package/src/media-store/backup/run.ts +6 -267
  160. package/src/media-store/backup/snapshot.ts +2 -38
  161. package/src/media-store/backup/sources.ts +3 -113
  162. package/src/media-store/backup/target-send.ts +5 -29
  163. package/src/media-store/db.ts +8 -7
  164. package/src/media-store/forget-one.ts +1 -1
  165. package/src/media-store/forget.ts +1 -80
  166. package/src/orchestrator/guards.ts +0 -1
  167. package/src/orchestrator/presence.ts +2 -2
  168. package/src/orchestrator/routes.ts +1 -1
  169. package/src/orchestrator/started.ts +0 -9
  170. package/src/orchestrator/talk-key.ts +3 -4
  171. package/src/orchestrator/unheard.ts +1 -1
  172. package/src/recordings/edit.ts +3 -3
  173. package/src/recordings/marks-draw.ts +17 -6
  174. package/src/recordings/marks.ts +120 -9
  175. package/src/reflections/reflections-queue.ts +3 -10
  176. package/src/release/notes.ts +1 -1
  177. package/src/release/public-clean.ts +66 -6
  178. package/src/release/run-bump.ts +11 -0
  179. package/src/release/run-release.ts +4 -0
  180. package/src/releases/from-thread.ts +3 -3
  181. package/src/releases/model.ts +186 -36
  182. package/src/releases/store.ts +13 -3
  183. package/src/releases/validate.ts +83 -0
  184. package/src/repo-config.ts +29 -64
  185. package/src/review/answer-kinds.ts +61 -4
  186. package/src/review/blocked-guard.ts +11 -0
  187. package/src/review/blocked-object.ts +298 -0
  188. package/src/review/cells.ts +116 -229
  189. package/src/review/close.ts +39 -1
  190. package/src/review/doc-save.ts +3 -2
  191. package/src/review/draft-item.ts +1 -1
  192. package/src/review/events.ts +3 -7
  193. package/src/review/expect.ts +23 -39
  194. package/src/review/format.ts +79 -46
  195. package/src/review/glyphs.ts +1 -0
  196. package/src/review/hand-over.ts +3 -3
  197. package/src/review/heard.ts +1 -1
  198. package/src/review/holds-sync.ts +2 -1
  199. package/src/review/inbox-hook.ts +2 -2
  200. package/src/review/inbox-read.ts +39 -33
  201. package/src/review/instruction-guards.ts +12 -0
  202. package/src/review/instructions.ts +0 -1
  203. package/src/review/item-db.ts +13 -43
  204. package/src/review/item-hq.ts +2 -2
  205. package/src/review/item-rows.ts +3 -14
  206. package/src/review/kind-catalog.ts +3 -1
  207. package/src/review/kinds.ts +18 -8
  208. package/src/review/live-view.ts +3 -0
  209. package/src/review/media-kind.ts +1 -1
  210. package/src/review/mentions.ts +1 -2
  211. package/src/review/model.ts +158 -114
  212. package/src/review/move.ts +149 -0
  213. package/src/review/need-threads.ts +3 -2
  214. package/src/review/object-card.ts +11 -0
  215. package/src/review/object-read.ts +6 -1
  216. package/src/review/one-block.ts +1 -1
  217. package/src/review/owner-read.ts +1 -1
  218. package/src/review/phone-push.ts +10 -9
  219. package/src/review/previews.ts +32 -4
  220. package/src/review/push.ts +2 -2
  221. package/src/review/recap.ts +129 -0
  222. package/src/review/referring.ts +6 -3
  223. package/src/review/reflection-object.ts +4 -3
  224. package/src/review/routes.ts +49 -19
  225. package/src/review/secret-route.ts +3 -2
  226. package/src/review/settle.ts +0 -6
  227. package/src/review/snooze.ts +5 -3
  228. package/src/review/speaker.ts +68 -0
  229. package/src/review/start-title.ts +19 -0
  230. package/src/review/store.ts +86 -59
  231. package/src/review/{wakes.ts → thread-events.ts} +92 -7
  232. package/src/review/thread-md.ts +35 -14
  233. package/src/review/thread-state.ts +798 -0
  234. package/src/review/threads.ts +29 -347
  235. package/src/review/traces.ts +104 -7
  236. package/src/review/trailer-item.ts +1 -1
  237. package/src/review/unit.ts +7 -9
  238. package/src/review/verdict-items.ts +12 -10
  239. package/src/review/view-layout.ts +25 -1
  240. package/src/review/watch-feed.ts +1 -2
  241. package/src/review/working-guards.ts +2 -3
  242. package/src/rules/untrack-generated.ts +1 -15
  243. package/src/secrets/lapse.ts +2 -1
  244. package/src/serve/hub-app/advisor-app.tsx +4 -4
  245. package/src/serve/hub-app/advisor-face.tsx +9 -3
  246. package/src/serve/hub-app/advisor-host.ts +27 -27
  247. package/src/serve/hub-app/advisors-model.ts +17 -8
  248. package/src/serve/hub-app/advisors-rights.tsx +1 -1
  249. package/src/serve/hub-app/advisors-st.ts +15 -14
  250. package/src/serve/hub-app/advisors-view.tsx +13 -11
  251. package/src/serve/hub-app/app-bridge.ts +23 -3
  252. package/src/serve/hub-app/asks-page.tsx +1 -1
  253. package/src/serve/hub-app/auto-text.tsx +71 -16
  254. package/src/serve/hub-app/check-view.tsx +0 -8
  255. package/src/serve/hub-app/controls.css +14 -3
  256. package/src/serve/hub-app/database-view.tsx +1 -2
  257. package/src/serve/hub-app/git-view.tsx +3 -1
  258. package/src/serve/hub-app/hub.css +12 -5
  259. package/src/serve/hub-app/icons.tsx +1 -1
  260. package/src/serve/hub-app/inbox-view.tsx +1 -2
  261. package/src/serve/hub-app/live-sources.ts +2 -2
  262. package/src/serve/hub-app/main-panel.tsx +2 -1
  263. package/src/serve/hub-app/panel-repo.ts +0 -9
  264. package/src/serve/hub-app/pic.tsx +29 -12
  265. package/src/serve/hub-app/polled.ts +16 -2
  266. package/src/serve/hub-app/recordings-st.ts +23 -2
  267. package/src/serve/hub-app/recordings-view.tsx +68 -10
  268. package/src/serve/hub-app/ref-pill.ts +1 -1
  269. package/src/serve/hub-app/repo-st.ts +1 -2
  270. package/src/serve/hub-app/review/advisor-add.tsx +1 -1
  271. package/src/serve/hub-app/review/advisor-invite.tsx +1 -1
  272. package/src/serve/hub-app/review/draft-body.tsx +2 -2
  273. package/src/serve/hub-app/review/heard-line.tsx +1 -1
  274. package/src/serve/hub-app/review/instructions-view.tsx +1 -8
  275. package/src/serve/hub-app/review/kind-states.tsx +14 -9
  276. package/src/serve/hub-app/review/kit.tsx +4 -11
  277. package/src/serve/hub-app/review/lane-bar.tsx +3 -3
  278. package/src/serve/hub-app/review/lightbox.tsx +15 -11
  279. package/src/serve/hub-app/review/line-window.ts +4 -1
  280. package/src/serve/hub-app/review/live-bar-st.ts +2 -2
  281. package/src/serve/hub-app/review/live-view.tsx +57 -1
  282. package/src/serve/hub-app/review/object-panel.tsx +20 -8
  283. package/src/serve/hub-app/review/question-views.tsx +181 -54
  284. package/src/serve/hub-app/review/recap-bar.tsx +40 -0
  285. package/src/serve/hub-app/review/request-cell.tsx +48 -0
  286. package/src/serve/hub-app/review/review-cells.tsx +154 -96
  287. package/src/serve/hub-app/review/review-host.ts +2 -2
  288. package/src/serve/hub-app/review/review-kit.ts +17 -11
  289. package/src/serve/hub-app/review/review-list.tsx +23 -31
  290. package/src/serve/hub-app/review/review-st.ts +30 -40
  291. package/src/serve/hub-app/review/review-thread.tsx +139 -85
  292. package/src/serve/hub-app/review/review-views.tsx +124 -68
  293. package/src/serve/hub-app/review/share-lines.tsx +4 -4
  294. package/src/serve/hub-app/review/start-st.ts +2 -5
  295. package/src/serve/hub-app/review/superseded-runs.ts +4 -3
  296. package/src/serve/hub-app/review/thread-close.tsx +10 -7
  297. package/src/serve/hub-app/review/thread-st.ts +372 -201
  298. package/src/serve/hub-app/review/tone-bar.tsx +126 -0
  299. package/src/serve/hub-app/review/tones.ts +35 -0
  300. package/src/serve/hub-app/review/trailer-body.tsx +2 -2
  301. package/src/serve/hub-app/review/trailer-st.ts +3 -2
  302. package/src/serve/hub-app/review/trailer-voices-st.ts +3 -2
  303. package/src/serve/hub-app/review.css +180 -106
  304. package/src/serve/hub-app/search-view.tsx +1 -1
  305. package/src/serve/hub-app/social/social-model.ts +0 -4
  306. package/src/serve/hub-app/source-acts.ts +2 -1
  307. package/src/serve/hub-app/stores/stores-page.tsx +2 -2
  308. package/src/serve/hub-app/terminal-sources.tsx +2 -1
  309. package/src/serve/hub-app/thread-row.tsx +3 -4
  310. package/src/serve/hub-app/tree-build.ts +0 -4
  311. package/src/serve/hub-app/urls-view.tsx +2 -1
  312. package/src/serve/hub-app/view-layout.css +13 -3
  313. package/src/serve/hub-app/wikis-view.tsx +5 -2
  314. package/src/serve/hub-runtime.ts +7 -37
  315. package/src/serve/project-gutter-route.ts +6 -2
  316. package/src/serve/read-thread.ts +20 -2
  317. package/src/serve/read-worker.ts +9 -1
  318. package/src/serve/record-pages.ts +46 -0
  319. package/src/serve/serve-hub.ts +2 -2
  320. package/src/serve/terminal-host.ts +1 -1
  321. package/src/serve/terminal-route.ts +1 -3
  322. package/src/serve/tracked-watch.ts +1 -3
  323. package/src/setup-house.ts +2 -2
  324. package/src/shipkit-files.ts +1 -1
  325. package/src/shipkit.ts +1 -6
  326. package/src/shot/film-box.ts +0 -20
  327. package/src/social/drafts.ts +1 -1
  328. package/src/social/kinds.ts +6 -29
  329. package/src/social/load.ts +2 -2
  330. package/src/social/post-object.ts +3 -2
  331. package/src/social/release-stage.ts +1 -1
  332. package/src/social/stage.ts +2 -2
  333. package/src/stores/model.ts +4 -0
  334. package/src/stores/routes.ts +11 -3
  335. package/src/suite/judge-suites.ts +58 -0
  336. package/src/suite/red-alone.ts +54 -18
  337. package/src/suite/runner-shapes.ts +2 -2
  338. package/src/suite/suite-cli.ts +67 -14
  339. package/src/suite/test-units.ts +2 -1
  340. package/src/urls/fill.ts +1 -1
  341. package/src/urls/places.ts +1 -2
  342. package/src/vault/vault-config.ts +2 -2
  343. package/src/vault/vault-init.ts +1 -5
  344. package/src/wiki/graph-page.ts +14 -2
  345. package/src/advisors/copy-truth.ts +0 -49
  346. package/src/advisors/door-child.ts +0 -112
  347. package/src/advisors/door-serve.ts +0 -52
  348. package/src/advisors/door.ts +0 -118
  349. package/src/checks/SK016-legacy-check-shapes.check.ts +0 -189
  350. package/src/checks/SK029-explicit-check-files.check.ts +0 -112
  351. package/src/checks/SK048-one-local-file.check.ts +0 -36
  352. package/src/core/config-rewrite.ts +0 -111
  353. package/src/core/daemon-port.ts +0 -10
  354. package/src/core/legacy-shapes.ts +0 -263
  355. package/src/core/migrate-layout.ts +0 -638
  356. package/src/core/port-check-cli.ts +0 -52
  357. package/src/core/port-check-file.ts +0 -295
  358. package/src/core/port-check-files.ts +0 -31
  359. package/src/gate/discover-legacy-checks.ts +0 -26
  360. package/src/home/home-move.ts +0 -527
  361. package/src/home/machine-fold.ts +0 -810
  362. package/src/hq/item-shapes.ts +0 -54
  363. package/src/hq/kinds/items-read.ts +0 -4
  364. package/src/media-store/backup/daemon.ts +0 -220
  365. package/src/media-store/backup/kept.ts +0 -241
  366. package/src/media-store/backup/prune.ts +0 -359
  367. package/src/media-store/backup/secret.ts +0 -88
  368. package/src/media-store/backup/ssh-space.ts +0 -202
  369. package/src/media-store/backup/watch.ts +0 -117
  370. package/src/review/band.ts +0 -182
  371. package/src/review/folders.ts +0 -216
  372. package/src/review/hook-ask.ts +0 -58
  373. package/src/review/role.ts +0 -48
  374. package/src/review/thread-fold.ts +0 -64
  375. package/src/review/wait.ts +0 -91
  376. package/src/rules/rule.ts +0 -43
  377. package/src/serve/hook-thread.ts +0 -37
  378. package/src/serve/hook-work.ts +0 -92
  379. package/src/serve/hook-worker.ts +0 -57
  380. package/src/serve/hub-app/review/dock.tsx +0 -147
  381. package/src/serve/hub-app/review/faces.tsx +0 -18
  382. package/src/serve/hub-app/review/item-verdict.tsx +0 -112
  383. package/src/serve/hub-app/review/review-board.tsx +0 -48
  384. /package/src/{scaffold → core}/jsonc-spans.ts +0 -0
@@ -20,8 +20,16 @@
20
20
  .rv-still.cover img{object-fit:cover}
21
21
  .rv-stillopen{position:absolute;right:var(--s2);bottom:var(--s2);padding:2px var(--s2);border-radius:6px;font-size:12px;font-weight:600;color:var(--bg);background:color-mix(in srgb,var(--ink) 70%,transparent);pointer-events:none}
22
22
  .rv-still:hover .rv-stillopen{background:var(--accent)}
23
- .rv-stilllink{position:absolute;left:var(--s2);bottom:var(--s2);padding:2px var(--s2);border-radius:6px;font-size:12px;font-weight:600;color:var(--bg);background:color-mix(in srgb,var(--ink) 70%,transparent);text-decoration:none}
24
- .rv-stilllink:hover{background:var(--accent)}
23
+ /* a live page's tile (live-view.tsx LiveTile): its shot in a border of its own colour, IFRAME on it, its ways to open
24
+ it in a column down its right side */
25
+ .rv-livetile{position:relative;display:flex;aspect-ratio:16/10;border:2px solid var(--iframe);border-radius:8px;overflow:hidden;background:var(--panel2)}
26
+ .rv-view.s-tile .rv-viewmedia > .rv-livetile,.rv-view.s-thumb .rv-viewmedia > .rv-livetile{position:absolute;inset:0;aspect-ratio:auto}
27
+ .rv-livetile > .rv-still{flex:1;min-width:0;height:100%}
28
+ .rv-iframetag{position:absolute;left:var(--s2);top:var(--s2);padding:var(--s0) var(--s2);border-radius:4px;font:700 11px/16px ui-monospace,Menlo,monospace;letter-spacing:.08em;color:var(--bg);background:var(--iframe);pointer-events:none}
29
+ .rv-iframerail{flex:none;display:flex;flex-direction:column;gap:var(--s1);padding:var(--s1);overflow:hidden;border-left:2px solid var(--iframe);background:color-mix(in srgb,var(--iframe) 14%,var(--panel))}
30
+ .rv-iframerail > :is(a,button){display:grid;place-items:center;flex:none;width:28px;height:28px;padding:0;border:1px solid color-mix(in srgb,var(--iframe) 45%,transparent);border-radius:6px;color:var(--iframe);background:var(--panel);cursor:pointer}
31
+ .rv-iframerail > :is(a,button):hover,.rv-iframerail > :is(a,button):focus-visible{color:var(--bg);background:var(--iframe)}
32
+ .rv-view.f-live .rv-viewtools{right:44px}
25
33
  .rv-stillplay{position:absolute;left:50%;top:50%;display:grid;place-items:center;width:44px;height:44px;border-radius:50%;transform:translate(-50%,-50%);font-size:17px;color:var(--bg);background:color-mix(in srgb,var(--ink) 60%,transparent);pointer-events:none}
26
34
 
27
35
  /* a pair: its after; the pointer on it cross fades to its before (PEEK_MS), a tap toggles it on touch */
@@ -64,8 +72,10 @@
64
72
  /* a gallery: equal tiles filling the row, --gmin the least width (its size control) */
65
73
  .rv-gtiles{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(100%,var(--gmin,208px)),1fr));gap:var(--s3) var(--s2)}
66
74
  .rv-gallerywrap.large .rv-gtiles{gap:var(--s2) var(--s1)}
75
+ /* a tile's picture: its size is its width and its ratio alone, so each is its own layout root, and one out of view is
76
+ not laid out at all */
67
77
  .rv-gtile{display:flex;flex-direction:column;gap:var(--s1);min-width:0;padding:0;border:0;background:none;color:inherit;text-align:left;cursor:zoom-in}
68
- .rv-gtileimg{position:relative;display:block;aspect-ratio:16/10;border-radius:8px;overflow:hidden;background:repeating-conic-gradient(var(--chk1) 0 25%,var(--chk2) 0 50%) 0 0/12px 12px;box-shadow:0 0 0 1px var(--line);transition:box-shadow .12s}
78
+ .rv-gtileimg{position:relative;display:block;aspect-ratio:16/10;border-radius:8px;overflow:hidden;background:repeating-conic-gradient(var(--chk1) 0 25%,var(--chk2) 0 50%) 0 0/12px 12px;box-shadow:0 0 0 1px var(--line);transition:box-shadow .12s;contain:strict;content-visibility:auto}
69
79
  .rv-gtileimg img{display:block;width:100%;height:100%;object-fit:contain}
70
80
  .rv-gtile:hover .rv-gtileimg,.rv-gtile:focus-visible .rv-gtileimg{box-shadow:0 0 0 2px var(--accent)}
71
81
  .rv-gtile[class*=' re-'] .rv-gtileimg{box-shadow:0 0 0 2px var(--tone)}
@@ -75,6 +75,7 @@ export const WikisView = observer(({ app, id, label }: { app: RepoSt; id: string
75
75
  const WikiBody = observer(({ app, w, href, title }: { app: RepoSt; w: WikiSt; href: string; title: string }) => {
76
76
  const el = useRef<HTMLDivElement | null>(null)
77
77
  const frame = useRef<HTMLIFrameElement | null>(null)
78
+ const [loaded, setLoaded] = useState(false)
78
79
  const theme = app.home.theme.scheme
79
80
  // the theme the graph first paints in rides its url; a later change is a message, never a reload
80
81
  const first = useRef(theme)
@@ -90,10 +91,12 @@ const WikiBody = observer(({ app, w, href, title }: { app: RepoSt; w: WikiSt; hr
90
91
  const below = w.place === 'bottom'
91
92
  const graph = (
92
93
  <Panel key="graph" id="wiki-graph" minSize={below ? 160 : 280} style={PANEL}>
93
- {/* the spinner sits under the frame: the graph page paints its own background over it the moment it has something to show */}
94
- <div className="gvframe"><span className="gvwait"><span className="spin" />reading the wiki…</span>
94
+ {/* the spinner sits under the frame until the graph page loaded, never longer: covered, it would still turn (a frame
95
+ of the compositor each refresh) for as long as the page stays open */}
96
+ <div className="gvframe">{loaded ? null : <span className="gvwait"><span className="spin" />reading the wiki…</span>}
95
97
  <iframe ref={(f) => { frame.current = f; w.setFrame(f?.contentWindow ?? null) }} src={`${app.url(href)}${sep}theme=${first.current}`} title={title}
96
98
  onLoad={() => {
99
+ setLoaded(true)
97
100
  w.setFrame(frame.current?.contentWindow ?? null)
98
101
  w.send({ type: 'wiki-graph:theme', theme: app.home.theme.scheme })
99
102
  if (w.page != null) w.send({ type: 'wiki-graph:focus', id: w.page.id })
@@ -26,10 +26,10 @@ import { pingTick } from '../collections/pings.ts'
26
26
  import { baseWikiRoot, configStamp, graphMounts, hubCollections } from './hub-collections.ts'
27
27
  import type { ReadThread } from './read-thread.ts'
28
28
  import { loadRepoConfig, type RepoConfig } from '../repo-config.ts'
29
- import { allTasks, gateInventory } from '../gate/gate-checks.ts'
29
+ import { allTasks } from '../gate/gate-checks.ts'
30
30
  import { runCheck, type CheckEvent } from '../gate/run-check.ts'
31
31
  import { runCi, type CiOpts } from '../gate/run-ci.ts'
32
- import { readInvocations, readLive, readRuns, readRunsSince, runsPath, sweepLive, warmRuns } from '../ledger/run-log.ts'
32
+ import { readInvocations, readLive, readRunsSince, runsPath, sweepLive } from '../ledger/run-log.ts'
33
33
  import { LIVE_HISTORY_MS, shapeLive, type LiveView } from '../ledger/live-timeline.ts'
34
34
  import { parallelCap } from '../core/parallel.ts'
35
35
  import { autoGatePool, takeSlot } from '../core/slots.ts'
@@ -41,12 +41,8 @@ import { OtherRepos } from './other-repos.ts'
41
41
  import { HouseRuns } from './house-runs.ts'
42
42
  import { runsPushStamp } from './runs-stamp.ts'
43
43
  import { recordStamp } from '../house/project-gutter.ts'
44
- import { shapeTimeline } from '../ledger/run-timeline.ts'
45
- import { readSuiteRuns, readSuites, warmSuites } from '../ledger/suite-log.ts'
46
- import { shapeTestCheck, shapeTestsRoot } from '../collections/test-time.ts'
47
- import type { NeedItem, TestFacts } from '../collections/collection-types.ts'
48
- import { declaredSlowFiles } from '../suite/test-units.ts'
49
- import { BUILD_TIMEOUT_MS, CHECK_TIMEOUT_MS } from '../collections/checks.ts'
44
+ import { recordTests, recordTimeline } from './record-pages.ts'
45
+ import type { NeedItem } from '../collections/collection-types.ts'
50
46
  import { watchTracked } from './tracked-watch.ts'
51
47
  import { repoSource } from '../plan/repo-source.ts'
52
48
  import type { PlanSource, Planner } from '../plan/planner.ts'
@@ -323,35 +319,9 @@ export async function resolveHubDeps(root: string, boot: RepoConfig, io: ServeIo
323
319
  // house repo, built on the first ask (a hub the daemon loads is never
324
320
  // asked, the daemon answers for the house)
325
321
  house: () => (house ??= houseOf(root, c.name)).view(),
326
- timeline: async () => {
327
- const ceilings: Record<string, number> = {}
328
- const budgets: Record<string, number> = {}
329
- const inventory = await gateInventory(root, c)
330
- for (const row of inventory) {
331
- ceilings[row.decl.id] = row.timeoutMs ?? (row.build ? BUILD_TIMEOUT_MS : CHECK_TIMEOUT_MS)
332
- budgets[row.decl.id] = row.budgetMs
333
- }
334
- await warmRuns(record)
335
- await warmSuites(record)
336
- return shapeTimeline({
337
- runs: readRuns(record),
338
- invocations: readInvocations(record),
339
- suites: readSuites(record),
340
- ceilings,
341
- budgets,
342
- inventory: inventory.map((row) => row.decl.id),
343
- declaredSlow: declaredSlowFiles(c),
344
- cap: parallelCap(),
345
- })
346
- },
347
- tests: async (check) => {
348
- // the SAME test files the tree lists, from the same provider
349
- const col = allCollections().find((x) => x.id === 'tests')
350
- const facts = col == null ? [] : (await col.list()).flatMap((i): TestFacts[] => (i.test == null ? [] : [i.test]))
351
- await warmRuns(record)
352
- const input = { facts, runs: readRuns(record), suiteRuns: readSuiteRuns(record) }
353
- return check == null || check === '' ? shapeTestsRoot(input) : shapeTestCheck(check, input)
354
- },
322
+ // the whole record read in the read thread, which holds it for the rows already (record-pages.ts)
323
+ timeline: () => (readThread == null ? recordTimeline(root, c, record) : readThread.timeline(root)),
324
+ tests: (check) => (readThread == null ? recordTests(allCollections(), record, check) : readThread.tests(root, check)),
355
325
  needs: () => projectNeeds(allCollections(), hubProblems.collector),
356
326
  hubProblems,
357
327
  // a job outlives this image, so only an in process run holds a reload back
@@ -32,7 +32,7 @@ import { storeDir, warmStore } from '../review/store.ts'
32
32
  import { writeArchived } from '../core/archived.ts'
33
33
  import { machinePath } from '../core/machine-layout.ts'
34
34
  import { identitiesDir, pictureVersion } from '../identities/identities.ts'
35
- import { identityCache, markFile, railOf, speakerIdOf, type RailIdentity } from '../identities/machine.ts'
35
+ import { identityCache, markFile, markPng, railOf, speakerIdOf, type RailIdentity } from '../identities/machine.ts'
36
36
  import { speaksAsOfText } from '../social/house.ts'
37
37
  import { isStoreRefused } from '../core/machine-db.ts'
38
38
  import { atomicWrite } from '../core/atomic-write.ts'
@@ -523,7 +523,11 @@ export function projectGutter(d: GutterDeps) {
523
523
  if (file == null || !existsSync(file)) return new Response(`no mark for the identity ${JSON.stringify(id)}`, { status: 404 })
524
524
  // the url names the file's version (markUrl): kept for good while it is the current one, else asked again
525
525
  const v = new URL(req.url).searchParams.get('v')
526
- return new Response(Bun.file(file), { headers: { 'cache-control': v != null && v !== '' && v === pictureVersion(file) ? 'public, max-age=31536000, immutable' : 'no-cache' } })
526
+ const now = pictureVersion(file)
527
+ const cache = { 'cache-control': v != null && v !== '' && v === now ? 'public, max-age=31536000, immutable' : 'no-cache' }
528
+ // the mark at the size the hub draws it (markPng), the file itself only when it does not decode
529
+ const png = await markPng(file, now)
530
+ return png == null ? new Response(Bun.file(file), { headers: cache }) : new Response(png, { headers: { ...cache, 'content-type': 'image/png' } })
527
531
  }
528
532
  if (path.startsWith('/api/projects/app-icon/')) {
529
533
  if (repos.length === 0) await answer()
@@ -7,8 +7,16 @@
7
7
  // new one; the warm cell and the parties' few seconds keep their last answer meanwhile
8
8
  import type { StoreParties } from '../review/store-parties.ts'
9
9
  import type { RowsAnswer } from './hub-collections.ts'
10
+ import type { Timeline } from '../ledger/run-timeline.ts'
11
+ import type { TestCheckView, TestsRootView } from '../collections/test-time.ts'
10
12
 
11
- export type ReadAsk = { id: number } & ({ kind: 'rows'; root: string; reset: boolean } | { kind: 'parties'; dir: string } | { kind: 'snapshot'; file: string })
13
+ export type ReadAsk = { id: number } & (
14
+ | { kind: 'rows'; root: string; reset: boolean }
15
+ | { kind: 'timeline'; root: string }
16
+ | { kind: 'tests'; root: string; check: string | null }
17
+ | { kind: 'parties'; dir: string }
18
+ | { kind: 'snapshot'; file: string }
19
+ )
12
20
  export type ReadReply = { id: number; answer: unknown } | { id: number; error: string }
13
21
 
14
22
  const ENTRY = new URL('./read-worker.ts', import.meta.url).href
@@ -17,7 +25,7 @@ const ENTRY = new URL('./read-worker.ts', import.meta.url).href
17
25
  type Ask = ReadAsk extends infer A ? (A extends { id: number } ? Omit<A, 'id'> : never) : never
18
26
 
19
27
  /** one worker thread that answers numbered asks (`{ id, answer }` or `{ id, error }`), started at the first ask and
20
- * again at the next one once it died: the read thread here, the hook thread (hook-thread.ts) */
28
+ * again at the next one once it died: the read thread here */
21
29
  export class WorkerThread<A extends object> {
22
30
  private w: Worker | null = null
23
31
  private next = 0
@@ -82,6 +90,16 @@ export class ReadThread extends WorkerThread<Ask> {
82
90
  return this.ask({ kind: 'rows', root, reset })
83
91
  }
84
92
 
93
+ /** the timeline page of the repo at `root`, from its whole run record (record-pages.ts) */
94
+ timeline(root: string): Promise<Timeline> {
95
+ return this.ask({ kind: 'timeline', root })
96
+ }
97
+
98
+ /** the tests page of the repo at `root`, of one check or of them all */
99
+ tests(root: string, check: string | null): Promise<TestsRootView | TestCheckView> {
100
+ return this.ask({ kind: 'tests', root, check })
101
+ }
102
+
85
103
  /** the parties of the store at `dir` */
86
104
  parties(dir: string): Promise<StoreParties> {
87
105
  return this.ask({ kind: 'parties', dir })
@@ -1,4 +1,5 @@
1
- // the daemon's read thread (read-thread.ts): every repo's rows and every store's parties read here, off the loop every
1
+ // the daemon's read thread (read-thread.ts): every repo's rows, its two pages of the whole run record and every
2
+ // store's parties read here, off the loop every
2
3
  // page waits on. Each repo keeps its config, kit and comfy mark between two computes of its rows, read again when its
3
4
  // config file moves, and from scratch when its hub loads again (`reset`).
4
5
  import { existsSync } from 'fs'
@@ -10,6 +11,8 @@ import { computeRows, configStamp, graphMounts, hubCollections } from './hub-col
10
11
  import { hubParties } from '../orchestrator/places.ts'
11
12
  import { installOneLib } from '../core/one-lib.ts'
12
13
  import { keepTranscriptListing } from '../agent-time/store.ts'
14
+ import { recordTests, recordTimeline } from './record-pages.ts'
15
+ import { runsPath } from '../ledger/run-log.ts'
13
16
  import type { ReadAsk, ReadReply } from './read-thread.ts'
14
17
 
15
18
  declare const self: Worker
@@ -53,6 +56,11 @@ async function answer(a: ReadAsk): Promise<ReadReply> {
53
56
  await Bun.write(a.file, Bun.generateHeapSnapshot('v8', 'arraybuffer'), { createPath: true })
54
57
  return { id: a.id, answer: process.memoryUsage().heapUsed }
55
58
  }
59
+ if (a.kind === 'timeline') return { id: a.id, answer: await recordTimeline(a.root, (await repoAt(a.root, false)).c, runsPath(a.root)) }
60
+ if (a.kind === 'tests') {
61
+ const t = await repoAt(a.root, false)
62
+ return { id: a.id, answer: await recordTests(hubCollections(a.root, t.c, t.kit, graphMounts(a.root, t.c), t.comfy), runsPath(a.root), a.check) }
63
+ }
56
64
  const r = await repoAt(a.root, a.reset)
57
65
  return { id: a.id, answer: await computeRows(hubCollections(a.root, r.c, r.kit, graphMounts(a.root, r.c), r.comfy)) }
58
66
  } catch (e) {
@@ -0,0 +1,46 @@
1
+ // the two pages shaped from a repo's run record: the timeline and the tests. Each reads the recent runs and suite rows
2
+ // of every check and test file, which record-kept.ts holds in memory for the thread that read them, bounded per key.
3
+ // The daemon asks both of its read thread (read-worker.ts), which holds that record for the rows already, so its loop's
4
+ // thread never holds a second copy; a hub serving alone computes them in process, through the same functions
5
+ import type { RepoConfig } from '../repo-config.ts'
6
+ import type { Collection, TestFacts } from '../collections/collection-types.ts'
7
+ import { gateInventory } from '../gate/gate-checks.ts'
8
+ import { readInvocations, readRuns, warmRuns } from '../ledger/run-log.ts'
9
+ import { readSuiteRuns, readSuites, warmSuites } from '../ledger/suite-log.ts'
10
+ import { shapeTimeline, type Timeline } from '../ledger/run-timeline.ts'
11
+ import { shapeTestCheck, shapeTestsRoot, type TestCheckView, type TestsRootView } from '../collections/test-time.ts'
12
+ import { declaredSlowFiles } from '../suite/test-units.ts'
13
+ import { parallelCap } from '../core/parallel.ts'
14
+ import { BUILD_TIMEOUT_MS, CHECK_TIMEOUT_MS } from '../collections/checks.ts'
15
+
16
+ /** every run on record, shaped for the timeline page */
17
+ export async function recordTimeline(root: string, c: RepoConfig, record: string): Promise<Timeline> {
18
+ const ceilings: Record<string, number> = {}
19
+ const budgets: Record<string, number> = {}
20
+ const inventory = await gateInventory(root, c)
21
+ for (const row of inventory) {
22
+ ceilings[row.decl.id] = row.timeoutMs ?? (row.build ? BUILD_TIMEOUT_MS : CHECK_TIMEOUT_MS)
23
+ budgets[row.decl.id] = row.budgetMs
24
+ }
25
+ await warmRuns(record)
26
+ await warmSuites(record)
27
+ return shapeTimeline({
28
+ runs: readRuns(record),
29
+ invocations: readInvocations(record),
30
+ suites: readSuites(record),
31
+ ceilings,
32
+ budgets,
33
+ inventory: inventory.map((row) => row.decl.id),
34
+ declaredSlow: declaredSlowFiles(c),
35
+ cap: parallelCap(),
36
+ })
37
+ }
38
+
39
+ /** the tests page, of one check or of them all: the SAME test files the tree lists, from the same provider */
40
+ export async function recordTests(collections: Collection[], record: string, check: string | null): Promise<TestsRootView | TestCheckView> {
41
+ const col = collections.find((x) => x.id === 'tests')
42
+ const facts = col == null ? [] : (await col.list()).flatMap((i): TestFacts[] => (i.test == null ? [] : [i.test]))
43
+ await warmRuns(record)
44
+ const input = { facts, runs: readRuns(record), suiteRuns: readSuiteRuns(record) }
45
+ return check == null || check === '' ? shapeTestsRoot(input) : shapeTestCheck(check, input)
46
+ }
@@ -380,12 +380,12 @@ export function hubHandler(d: HubDeps, o: { base?: string; projects?: Gutter } =
380
380
  }
381
381
  if (path.startsWith('/api/act/') && req.method === 'POST') {
382
382
  // act-in-place verbs: an ask's act lands in its thread, an asset note in its file; errors surface as
383
- // 400 text the card shows verbatim. An ask is named by its id (`ask`), or by `file` from an older page.
383
+ // 400 text the card shows verbatim. An ask is named by its id (`ask`).
384
384
  // A secret value has no verb here: it goes to its thread's secret route alone (review/secret-route.ts)
385
385
  // a parse error quotes the body, which can carry a pasted secret
386
386
  const b = (await req.json().catch(() => null)) as Record<string, string> | null
387
387
  if (b == null || typeof b !== 'object') return new Response('the body is not a json object', { status: 400 })
388
- const ask = b.ask ?? b.file ?? ''
388
+ const ask = b.ask ?? ''
389
389
  try {
390
390
  if (path === '/api/act/ask-done') askDone(d.root, ask)
391
391
  else if (path === '/api/act/ask-decline') askDecline(d.root, ask, typeof b.why === 'string' ? b.why : undefined)
@@ -12,7 +12,7 @@
12
12
  import { existsSync, mkdirSync, readFileSync, writeFileSync } from 'fs'
13
13
  import { dirname, join } from 'path'
14
14
  import { homeDir } from '../home/home-paths.ts'
15
- import { AGENT_ENV } from '../vault/vault-init.ts'
15
+ import { AGENT_ENV } from '../core/agent-env.ts'
16
16
  import { KEPT_ID, type KeptTerminal, type TerminalRecord } from './terminal-record.ts'
17
17
 
18
18
  /** one terminal as tmux has it */
@@ -378,13 +378,11 @@ export function terminalRoutes(d: TerminalDeps) {
378
378
  const why = hop ? terminalHopRefusal(req, d.hop) : terminalRefusal(req, srv.requestIP(req)?.address ?? null)
379
379
  if (why != null) return new Response(why, { status: 403, headers: NO_STORE })
380
380
  const scope = hop ? d.name : null
381
- const b = (await req.json().catch(() => null)) as { page?: unknown; key?: unknown; id?: unknown; cols?: unknown; rows?: unknown; lines?: unknown; attach?: unknown; act?: unknown; window?: unknown; name?: unknown; account?: unknown; type?: unknown; data?: unknown } | null
381
+ const b = (await req.json().catch(() => null)) as { page?: unknown; key?: unknown; id?: unknown; cols?: unknown; rows?: unknown; lines?: unknown; act?: unknown; window?: unknown; name?: unknown; account?: unknown; type?: unknown; data?: unknown } | null
382
382
  if (b == null || typeof b !== 'object') return new Response('the body is no json object', { status: 400, headers: NO_STORE })
383
383
  if (path === '/api/terminal/close') return closePart(b, scope)
384
384
  if (path === '/api/terminal/watch') return watch(b, scope)
385
385
  if (path === '/api/terminal/open') {
386
- // a session of another server is never attached by its name: every terminal the hub shows is the host's
387
- if (b.attach != null) return new Response('a session is no longer shown by its name: the orchestrator is a terminal of the project, in the main panel', { status: 404, headers: NO_STORE })
388
386
  return open(b, scope, size(b.cols, 2, 500, 80), size(b.rows, 2, 200, 24), typeof b.window === 'string' && /^@\d+$/.test(b.window) ? b.window : null)
389
387
  }
390
388
  // a part of a hop is acted on by that hop alone, a part of a page of this machine by such a page alone
@@ -4,7 +4,6 @@
4
4
  // problems pane until the next save, never a green.
5
5
  import { statSync } from 'fs'
6
6
  import { join } from 'path'
7
- import { GENERATED_IGNORE_LINES } from '../rules/untrack-generated.ts'
8
7
  import { gitBin } from '../core/git-bin.ts'
9
8
  import { LAYOUT } from '../core/layout.ts'
10
9
  import { followTree, treeMoved } from '../core/tree-rev.ts'
@@ -12,11 +11,10 @@ import { yieldLoop } from '../core/loop-watch.ts'
12
11
  import { watchTree } from '../core/tree-watch.ts'
13
12
 
14
13
  /** every path a run of the gate or the hub itself writes, whatever the repo
15
- * ignores: the status files, the per run logs under the scratch dir, an atomic write's
14
+ * ignores: the per run logs under the scratch dir, an atomic write's
16
15
  * temp file, the comfy state the hub writes at boot. A save there is the
17
16
  * machine's own, and triggering on it would schedule the next run forever */
18
17
  export const GATE_WRITES: readonly string[] = [
19
- ...GENERATED_IGNORE_LINES.filter((l) => !l.startsWith('#')),
20
18
  `${LAYOUT.tmp}/`,
21
19
  '.*.tmp-*',
22
20
  '.comfy-ts/',
@@ -13,7 +13,7 @@ import { CONTEXT_FILE, CONTEXT_INCLUDE } from './context/context-view.ts'
13
13
  import { LIB_VERSION } from './core/lib-version.ts'
14
14
  import { consumerOf } from './core/machine-link.ts'
15
15
  import { runner, type Run } from './git-bootstrap.ts'
16
- import { installedHouseRoot, LEGACY_LABEL, plistPath } from './home/home-launchd.ts'
16
+ import { installedHouseRoot, plistPath } from './home/home-launchd.ts'
17
17
  import { daemonUp, homeUp, pmUp } from './home/home-paths.ts'
18
18
  import { includeTargets } from './house/project-gutter.ts'
19
19
  import { initRepo } from './init-repo.ts'
@@ -116,7 +116,7 @@ export async function refusals(o: { repo: string; house: string; home: string; s
116
116
  const runs = installedHouseRoot(plistPath(o.home))
117
117
  const ours = runs != null && real(runs) === real(o.house)
118
118
  if (!ours) {
119
- const marks = [plistPath(o.home), plistPath(o.home, LEGACY_LABEL), join(o.home, '.shipkit', 'home', 'pm.log'), join(o.home, '.shipkit', 'home', 'state.json'), join(o.home, '.config', 'shipkit', 'home', 'pm.log')]
119
+ const marks = [plistPath(o.home), join(o.home, '.shipkit', 'home', 'pm.log')]
120
120
  for (const m of marks) if (existsSync(m)) out.push(`this machine already runs a shipkit house (${m} exists): sk setup makes the first one only. Wire a repo into the house you have with \`sk start <name>\` or \`sk init\``)
121
121
  if (!o.scratch) for (const role of await o.portsUp()) out.push(`a shipkit ${role} answers on this machine: a house already runs here, so sk setup stops. To rehearse beside it, give the run a scratch home (--home) and its own ports (SHIPKIT_PM_PORT, SHIPKIT_DAEMON_PORT, SHIPKIT_HOME_PORT)`)
122
122
  }
@@ -9,7 +9,7 @@
9
9
  // trailer({...}) what `sk trailer` cannot read from a file: the
10
10
  // sounds the repo resolves by id (trailer/adapter.ts)
11
11
  // review({...}) the repo's parts of the review store: its subject
12
- // kinds, topics, sources, auto rules, the dispatcher
12
+ // kinds, topics, sources, auto rules, its verbs
13
13
  // (review/unit.ts)
14
14
  // social({...}) the repo's parts of the social desks: its topics,
15
15
  // its articles and their preview (social/unit.ts)
package/src/shipkit.ts CHANGED
@@ -28,8 +28,6 @@ export { deriveRemote, dirtyPaths, remoteTags, strandedTags, tagExistsLocally }
28
28
  export { collectReports, renderReports, attentionLines } from './release/run-releases.ts'
29
29
  export { extractChangelogSection, promoteUnreleased, hasUnreleasedNotes, hasVersionSection } from './release/changelog.ts'
30
30
  export type { UnitReport } from './release/run-releases.ts'
31
- export { discoverLegacyChecks } from './gate/discover-legacy-checks.ts'
32
- export type { LegacyCheck } from './gate/discover-legacy-checks.ts'
33
31
  // THE runner: one DAG over every check, whatever declared it
34
32
  export { runChecks, selectChecks } from './gate/check-runner.ts'
35
33
  export type { RunnableCheck, CheckResult, CheckEvent, RunChecksOpts, RunChecksSummary } from './gate/check-runner.ts'
@@ -44,10 +42,7 @@ export { writeStatus } from './core/write-status.ts'
44
42
  export type { StatusInput, StatusOutcome } from './core/write-status.ts'
45
43
  export { formatLine, parseDuration, fmtStamp, parseWireOutput } from './core/wire.ts'
46
44
  export type { Line } from './core/wire.ts'
47
- // the SK rule registry — stable-id invariants `shipkit check` enforces;
48
- // consumers (e.g. a wiki lint verifying mentioned ids exist) read RULES
49
- export { tagRuleLines } from './rules/rule.ts'
50
- export type { Rule, RuleEnv, FixResult } from './rules/rule.ts'
45
+ export type { FixResult } from './check.ts'
51
46
  export { evaluateContracts, pngDims } from './contracts/contracts-engine.ts'
52
47
  export type { ContractsConfig, ContractsResult, ContractOutcome } from './contracts/contracts-engine.ts'
53
48
  export { defineContract, validateManifest, file, png, glob, md, dir, custom, script, fileContains, dirExists } from './contracts/contract-types.ts'
@@ -39,10 +39,6 @@ const DEAF_SWEEPS = 6
39
39
  const DIR = join(homedir(), 'dev', 'shipkit-film')
40
40
  const SLOTS = join(DIR, 'slots')
41
41
  const LOG = join(DIR, 'film-box.log')
42
- /** the one browser of older versions, ended once it drives no page */
43
- const LEGACY_PID = join(DIR, 'browser.pid')
44
- const LEGACY_USED = join(DIR, 'used')
45
- const LEGACY_QUIET_MS = 2 * 60_000
46
42
  const say = (s: string) => console.error(`box: ${s}`)
47
43
 
48
44
  /** this script's version: a slot's browser another version started is replaced */
@@ -290,7 +286,6 @@ async function start(version: string, key: string, t: number): Promise<void> {
290
286
  let b: SlotBrowser
291
287
  let luid: string | null
292
288
  try {
293
- await endLegacy()
294
289
  const exe = chromium(version)
295
290
  luid = await discreteLuid(exe.full)
296
291
  if (luid == null) say('no discrete GPU named in chrome://gpu: the browser draws on the default adapter')
@@ -313,21 +308,6 @@ async function start(version: string, key: string, t: number): Promise<void> {
313
308
  console.log(`up started ${Math.round(performance.now() - t)} port ${b.port} pid ${b.pid}${luid ? ` luid ${luid}` : ''}`)
314
309
  }
315
310
 
316
- /** the one browser older versions shared between every film, ended once no film drives a page in it and none asked
317
- * for it in LEGACY_QUIET_MS (a process still running older code connects between its up and its first page) */
318
- async function endLegacy(): Promise<void> {
319
- if (!existsSync(LEGACY_PID)) return
320
- if (Date.now() - (statSync(LEGACY_USED, { throwIfNoEntry: false })?.mtimeMs ?? 0) < LEGACY_QUIET_MS) return
321
- const [pid, , port] = readFileSync(LEGACY_PID, 'utf8').trim().split(' ')
322
- const busy = await pages(Number(port) || CDP_PORT).then(
323
- (p) => p.some((t) => t.attached),
324
- () => false,
325
- )
326
- if (busy) return
327
- await end(Number(pid), 'the shared browser of an older film-box version')
328
- rmSync(LEGACY_PID, { force: true })
329
- }
330
-
331
311
  async function watch(key: string, pid: number, port: number): Promise<void> {
332
312
  let orphans = new Set<string>()
333
313
  let deaf = 0
@@ -145,7 +145,7 @@ export function mediaNames(d: ParsedDraft): string[] {
145
145
  }
146
146
 
147
147
  /** where a media name points: `/…` or `~/…` anywhere on the disk, else the draft's folder, else the repo's root; null
148
- * when none holds it */
148
+ * when none holds it (a house repo's own scripts read it) */
149
149
  export function resolveMedia(name: string, dir: string, repo: string): string | null {
150
150
  if (name.startsWith('~/')) return existsSync(join(homedir(), name.slice(2))) ? join(homedir(), name.slice(2)) : null
151
151
  if (isAbsolute(name)) return existsSync(name) ? name : null
@@ -1,5 +1,5 @@
1
1
  // what a post is for (wiki guides/post-kinds/index.md): the closed set of kinds a draft's `kind` takes, a project's
2
- // own kinds from its social unit, the old words each kind replaces, and the one check the load and SK042 share. Pure:
2
+ // own kinds from its social unit, and the one check the load and SK042 share. Pure:
3
3
  // the unit module and the hub page import it
4
4
 
5
5
  /** the shared kinds, in the order the desk lists them */
@@ -32,20 +32,6 @@ export interface OwnKind {
32
32
  page: string
33
33
  }
34
34
 
35
- /** the words in use before the set closed, each with the kind it maps to by default; null: a text that stays on a
36
- * venue, a profile row of the identity and no post kind */
37
- export const OLD_KINDS: Readonly<Record<string, PostKind | null>> = {
38
- hello: 'announcement',
39
- welcome: 'announcement',
40
- devlog: 'iteration',
41
- wip: 'iteration',
42
- look: 'iteration',
43
- roundup: 'iteration',
44
- people: 'showcase',
45
- puzzle: 'showcase',
46
- page: null,
47
- }
48
-
49
35
  export const isPostKind = (k: string): k is PostKind => (POST_KINDS as readonly string[]).includes(k)
50
36
 
51
37
  /** a front matter value as written, trimmed and out of one pair of quotes: `"feature"` is feature, `""` is empty */
@@ -54,25 +40,16 @@ const unquote = (v: string | undefined): string => (v ?? '').trim().replace(/^([
54
40
  /** a draft's kind and its `kindWhy`, read the one way the load and SK042 read them */
55
41
  export const kindOfMeta = (meta: Readonly<Record<string, string | undefined>>): { kind: string; why: string } => ({ kind: unquote(meta['kind']), why: unquote(meta['kindWhy']) })
56
42
 
57
- /** why a draft's kind is wrong, or null; `old`: a word of the old words table, which a gate only warns on */
58
- export type KindProblem = { text: string; old: boolean }
59
-
60
43
  const INDEX = 'wiki guides/post-kinds/index.md'
61
44
 
62
- /** the kind a draft names, with its `kindWhy`, against the shared set and the project's own kinds */
63
- export function kindProblem(kind: string, why: string, own: readonly Pick<OwnKind, 'id'>[]): KindProblem | null {
45
+ /** why the kind a draft names, with its `kindWhy`, is none of the shared set and the project's own kinds, or null */
46
+ export function kindProblem(kind: string, why: string, own: readonly Pick<OwnKind, 'id'>[]): string | null {
64
47
  const k = kind.trim()
65
48
  const set = [...POST_KINDS, ...own.map((o) => o.id)].join(', ')
66
- if (k === '') return { text: `no kind: a draft names what it is for, one of ${set} (${INDEX})`, old: false }
67
- if (k === 'custom') return why.trim() === '' ? { text: `kind custom names no kindWhy: one line on why no kind fits (wiki ${kindPage('custom')})`, old: false } : null
49
+ if (k === '') return `no kind: a draft names what it is for, one of ${set} (${INDEX})`
50
+ if (k === 'custom') return why.trim() === '' ? `kind custom names no kindWhy: one line on why no kind fits (wiki ${kindPage('custom')})` : null
68
51
  if (isPostKind(k) || own.some((o) => o.id === k)) return null
69
- if (k in OLD_KINDS) {
70
- const to = OLD_KINDS[k]
71
- return to == null
72
- ? { text: `kind "${k}" is an old word and no post kind: a text that stays on a venue is a profile row of the identity (wiki tools/shipkit/social-identities.md)`, old: true }
73
- : { text: `kind "${k}" is an old word: ${to} by default, or the kind its intent reads as (wiki guides/post-kinds/old-words.md)`, old: true }
74
- }
75
- return { text: `kind "${k}" is not one of ${set}: a project's own kind is declared in its social unit's kinds (${INDEX})`, old: false }
52
+ return `kind "${k}" is not one of ${set}: a project's own kind is declared in its social unit's kinds (${INDEX})`
76
53
  }
77
54
 
78
55
  const WORD = /^[a-z][a-z0-9-]*$/
@@ -345,8 +345,8 @@ export function deskOf(root: string, ids: Identities, sources: readonly DraftSou
345
345
  }
346
346
  const kp = kindProblem(draft.kind, draft.kindWhy, unit?.kinds ?? [])
347
347
  if (kp != null) {
348
- draft.kindProblem = kp.text
349
- ;(kp.old ? warnings : errors).push(`${file}: ${kp.text}`)
348
+ draft.kindProblem = kp
349
+ errors.push(`${file}: ${kp}`)
350
350
  }
351
351
  const landings = new Map<string, Landing[]>()
352
352
  const placesFor = (a: DeskAccount): Landing[] => landings.get(a.id) ?? (landings.set(a.id, placesOf(a, errors)), landings.get(a.id)!)
@@ -1,10 +1,11 @@
1
1
  // one post's page (wiki tools/shipkit/social.md, Posts and their groups): the post as the desk loads it, its group and
2
2
  // siblings, its versions, and every thread that refers to it, the open ones first. Read only
3
3
  import { readAllCached, specOf, storeDir } from '../review/store.ts'
4
- import { membersOf, ownAddressesOf, threadsOf, threadTitle, turnOf } from '../review/threads.ts'
4
+ import { membersOf, ownAddressesOf, threadsOf, threadTitle } from '../review/threads.ts'
5
5
  import { accountOf, type Desk } from './load.ts'
6
6
  import { groupNow } from './post-sources.ts'
7
7
  import { postHistory, threadsReferring } from './posts.ts'
8
+ import { threadState } from '../review/thread-state.ts'
8
9
 
9
10
  export interface ThreadRef {
10
11
  /** what `sk thread show` and the threads page take: the thread's own address, else an item id of it */
@@ -31,7 +32,7 @@ export function refsOf(root: string, slug: string): ThreadRef[] {
31
32
  const out: ThreadRef[] = []
32
33
  for (const key of threadsReferring(root, slug)) {
33
34
  const t = threads.find((x) => ownAddressesOf(x, specOf(dir)).includes(key) || membersOf(x).some((m) => m.item.id === key))
34
- if (t != null) out.push({ key, id: t.head.item.id, title: threadTitle(t), open: turnOf(t) !== 'done' })
35
+ if (t != null) out.push({ key, id: t.head.item.id, title: threadTitle(t), open: threadState(t).active })
35
36
  }
36
37
  return out.sort((a, b) => Number(b.open) - Number(a.open))
37
38
  }
@@ -251,7 +251,7 @@ export function releaseThreads(root: string, slug: string): { range: string; thr
251
251
  const threads = threadsOf(items)
252
252
  .filter(ships)
253
253
  .map((t) => t.head)
254
- .filter((x) => x.item.origin.by === 'agent' && isApproved(verdictOf(x)?.status ?? 'rejected'))
254
+ .filter((x) => x.item.origin.by === 'agent' && isApproved(verdictOf(x)?.status ?? 'rework'))
255
255
  .sort((a, b) => b.item.created.localeCompare(a.item.created))
256
256
  .map((x) => ({ id: x.item.id, title: x.item.title, media: stageablesOf(x.item, 1) }))
257
257
  return { range, threads }
@@ -122,12 +122,12 @@ export function draftText(input: StageInput, media: string | null): string {
122
122
  export const stageSlug = (title: string, now: Date): string => idOf(now, title)
123
123
 
124
124
  /** the guard's problems with what the stage would write, and its kind's: run before any file is. A stage never writes
125
- * an old word or a custom with no reason, so every kind problem refuses it */
125
+ * a word off the set or a custom with no reason, so every kind problem refuses it */
126
126
  export function guardStage(unit: SocialUnit | null, input: StageInput): string[] {
127
127
  const kind = kindProblem(stagedKind(input), input.kindWhy ?? '', unit?.kinds ?? [])
128
128
  return [
129
129
  ...guardWith(unit, { title: input.title, alt: input.alt ?? '', texts: [input.text, ...(input.tags?.trim() ? [input.tags] : [])], files: stageMedia(input).map((m) => m.file) }),
130
- ...(kind ? [kind.text] : []),
130
+ ...(kind ? [kind] : []),
131
131
  ]
132
132
  }
133
133
 
@@ -3,6 +3,10 @@
3
3
  // its ask, the contract's lines. No fs, no fetch: desk.ts reads the files, the hub page imports this too
4
4
 
5
5
  export const STORE_IDS = ['steam', 'itch', 'chrome-web-store'] as const
6
+
7
+ /** the width a picture tile of the stores page loads (its file's url with `w`), in px: a tile draws about 456 px
8
+ * wide, sharp at 2x. The real size view and the lightbox load the file itself */
9
+ export const TILE_W = 960
6
10
  export type StoreId = (typeof STORE_IDS)[number]
7
11
  export const isStore = (s: unknown): s is StoreId => (STORE_IDS as readonly unknown[]).includes(s)
8
12
 
@@ -8,8 +8,9 @@ import { machineCommit } from '../core/machine-commit.ts'
8
8
  import { bad, FRESH, NO_STORE, ranged } from '../review/http.ts'
9
9
  import { noteOn } from '../review/notes.ts'
10
10
  import { openReview } from '../review/project.ts'
11
+ import { sizedImage } from '../review/previews.ts'
11
12
  import { FILE_ROUTE, loadStoresUnit, pasteHash, readPasted, shownFile, storesState, textFiles } from './desk.ts'
12
- import { fieldAsset, isStore, PASTED_FILE, setSection, STORE_DIR, STORE_NAME, type StoreId } from './model.ts'
13
+ import { fieldAsset, isStore, PASTED_FILE, setSection, STORE_DIR, STORE_NAME, TILE_W, type StoreId } from './model.ts'
13
14
  import { RENDER_FAMILIES, RENDER_TARGET, type RenderFamily } from './unit.ts'
14
15
 
15
16
  /** one make again at a time, per repo */
@@ -134,8 +135,15 @@ export async function storesRoutes(root: string, req: Request, path: string): Pr
134
135
  return Response.json(await storesState(root, dir), { headers: NO_STORE })
135
136
  }
136
137
  if (path.startsWith(FILE_ROUTE) && req.method === 'GET') {
137
- const abs = shownFile(root, decodeURIComponent(path.slice(FILE_ROUTE.length)))
138
- return abs ? ranged(req, abs, FRESH) : bad(`${path}?`, 404)
138
+ const rel = decodeURIComponent(path.slice(FILE_ROUTE.length))
139
+ const abs = shownFile(root, rel)
140
+ if (!abs) return bad(`${path}?`, 404)
141
+ // a tile asks its picture at the width it draws (TILE_W): a copy made once, the file itself when it does not read
142
+ if (new URL(req.url).searchParams.get('w') === String(TILE_W)) {
143
+ const small = await sizedImage(abs, join(root, '.shipkit', 'cache', 'previews', 'stores'), rel, TILE_W)
144
+ if (small) return new Response(Bun.file(small), { headers: { 'content-type': 'image/webp', 'cache-control': 'private, max-age=31536000, immutable' } })
145
+ }
146
+ return ranged(req, abs, FRESH)
139
147
  }
140
148
  if (req.method !== 'POST') return bad(`stores: no route ${req.method} ${path}`, 404)
141
149
  const body = (await req.json().catch(() => ({}))) as Record<string, unknown>