rvlib-shipkit 2.31.0 → 2.33.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.
- package/CHANGELOG.md +51 -0
- package/package.json +1 -1
- package/src/advisors/acts.ts +16 -15
- package/src/advisors/advice.ts +56 -102
- package/src/advisors/advisor-view.ts +122 -76
- package/src/advisors/app-graph.ts +1 -1
- package/src/advisors/app.ts +3 -11
- package/src/advisors/cf-api.ts +1 -1
- package/src/advisors/dir-bucket.ts +4 -3
- package/src/advisors/edge/api.ts +20 -221
- package/src/advisors/edge/bucket.ts +2 -2
- package/src/advisors/edge/handler.ts +13 -155
- package/src/advisors/edge/here.ts +5 -5
- package/src/advisors/edge/pages.ts +12 -9
- package/src/advisors/edge/shell.ts +6 -5
- package/src/advisors/edge/sign-in.ts +101 -36
- package/src/advisors/edge/status.ts +19 -6
- package/src/advisors/edge/types.ts +36 -60
- package/src/advisors/expose.ts +29 -29
- package/src/advisors/here.ts +12 -12
- package/src/advisors/invite-send.ts +79 -35
- package/src/advisors/invite.ts +31 -8
- package/src/advisors/job.ts +24 -16
- package/src/advisors/login.ts +40 -15
- package/src/advisors/owner-store.ts +46 -22
- package/src/advisors/photos.ts +3 -3
- package/src/advisors/project.ts +27 -25
- package/src/advisors/reach.ts +89 -0
- package/src/advisors/rights.ts +1 -1
- package/src/advisors/routes.ts +55 -74
- package/src/advisors/scan.ts +0 -4
- package/src/advisors/setup-run.ts +14 -14
- package/src/advisors/share-trace.ts +3 -3
- package/src/advisors/{door-probe.ts → sign-in-probe.ts} +7 -6
- package/src/advisors/speaks.ts +29 -0
- package/src/advisors/sync.ts +97 -183
- package/src/advisors/tunnel.ts +6 -5
- package/src/advisors/users-listen.ts +92 -0
- package/src/advisors/users-router.ts +261 -87
- package/src/advisors/users-store.ts +81 -0
- package/src/agent-time/blocked-scan.ts +181 -0
- package/src/agent-time/registry.ts +12 -5
- package/src/agent-time/store.ts +9 -109
- package/src/asks/ask-bar-fold.ts +2 -1
- package/src/asks/ask-close.ts +2 -1
- package/src/asks/ask-doc.ts +2 -1
- package/src/asks/ask-migrate.ts +3 -2
- package/src/asks/ask-steps-fold.ts +2 -1
- package/src/asks/ask-store.ts +4 -3
- package/src/check.ts +3 -43
- package/src/checks/SK001-package-json-shape.check.ts +4 -55
- package/src/checks/SK004-gitignore-policy.check.ts +24 -69
- package/src/checks/SK013-one-way-in-policy.check.ts +3 -7
- package/src/checks/SK017-vscode-hub-task.check.ts +4 -4
- package/src/checks/SK019-tests-run-in-units.check.ts +3 -14
- package/src/checks/SK020-self-spawning-check.check.ts +5 -7
- package/src/checks/SK035-public-clean.check.ts +1 -1
- package/src/checks/SK039-vscode-watch-generated.check.ts +1 -1
- package/src/checks/SK042-post-kinds.check.ts +5 -14
- package/src/checks/SK054-agent-allow-list.check.ts +5 -74
- package/src/checks/SK055-retired-config-keys.check.ts +45 -0
- package/src/cli/cmd_Advisors.ts +11 -45
- package/src/cli/cmd_Asks.ts +3 -10
- package/src/cli/cmd_Backup.ts +25 -127
- package/src/cli/cmd_BackupTargets.ts +1 -1
- package/src/cli/cmd_Capacity.ts +6 -2
- package/src/cli/cmd_Checks.ts +0 -14
- package/src/cli/cmd_Ci.ts +2 -1
- package/src/cli/cmd_Db.ts +3 -82
- package/src/cli/cmd_Home.ts +4 -32
- package/src/cli/cmd_Hq.ts +0 -17
- package/src/cli/cmd_Releases.ts +57 -4
- package/src/cli/cmd_Review.ts +333 -354
- package/src/cli/cmd_Shot.ts +26 -4
- package/src/cli/cmd_SocialDrafts.ts +6 -13
- package/src/cli/cmd_ThreadSyncNeeds.ts +6 -2
- package/src/cli/cmd_Time.ts +1 -1
- package/src/cli/cmd_Trailer.ts +1 -1
- package/src/cli/inbox-hook-run.ts +5 -23
- package/src/cli/registry-heads.ts +5 -55
- package/src/cli/registry.ts +1 -5
- package/src/cli/review-here.ts +1 -1
- package/src/cli.ts +15 -4
- package/src/collections/collection-types.ts +1 -1
- package/src/collections/review.ts +5 -4
- package/src/core/admission.ts +268 -0
- package/src/core/agent-allow-policy.ts +32 -2
- package/src/core/agent-env.ts +8 -0
- package/src/core/allow-rows.ts +74 -0
- package/src/core/check-file-names.ts +19 -106
- package/src/core/code-lines.ts +36 -21
- package/src/core/footprint.ts +17 -13
- package/src/core/identities-root.ts +1 -4
- package/src/core/layout.ts +1 -2
- package/src/core/machine-db.ts +33 -208
- package/src/core/machine-layout.ts +14 -127
- package/src/core/machine-read.ts +5 -2
- package/src/core/mask-source.ts +60 -0
- package/src/core/memory-watch.ts +17 -14
- package/src/core/motherhome.ts +8 -35
- package/src/core/one-way-in-policy.ts +0 -3
- package/src/core/peer-sk.ts +8 -0
- package/src/core/repo-walk.ts +0 -9
- package/src/core/retention.ts +1 -9
- package/src/core/retired-checks.ts +2 -0
- package/src/core/tmux-policy.ts +1 -1
- package/src/core/tree-watch.ts +2 -2
- package/src/core/when.ts +7 -45
- package/src/gate/admit-heavy.ts +150 -0
- package/src/gate/check-runner.ts +6 -0
- package/src/gate/discover-checks.ts +42 -32
- package/src/gate/gate-checks.ts +21 -131
- package/src/gate/head-gate.ts +1 -1
- package/src/gate/job-run.ts +2 -1
- package/src/gate/pre-commit-discovery.ts +22 -28
- package/src/gate/run-check.ts +3 -4
- package/src/gate/run-ci.ts +4 -0
- package/src/gate/run-fix.ts +5 -17
- package/src/gate/run-fixers.ts +6 -42
- package/src/home/app-sign.ts +2 -2
- package/src/home/backup-status.ts +52 -92
- package/src/home/backup-verdict.ts +2 -2
- package/src/home/daemon-jobs.ts +51 -95
- package/src/home/database-words.ts +1 -2
- package/src/home/databases.ts +9 -25
- package/src/home/home-launchd.ts +0 -6
- package/src/home/home-paths.ts +8 -4
- package/src/home/home-routes.ts +3 -10
- package/src/home/home-state.ts +2 -14
- package/src/home/inbox-shape.ts +14 -15
- package/src/home/inbox.ts +1 -1
- package/src/home/machine-repair.ts +102 -103
- package/src/home/resume.ts +1 -15
- package/src/home/run-daemon.ts +7 -12
- package/src/home/space-page.ts +3 -2
- package/src/home/supervise.ts +3 -7
- package/src/hooks/commit-msg-run.ts +61 -0
- package/src/hooks/commit-run.ts +16 -166
- package/src/hooks/gate-outcome.ts +108 -0
- package/src/hooks/git-hook.ts +9 -9
- package/src/hooks/hook-config.ts +8 -8
- package/src/hooks/leak-guard.ts +1 -1
- package/src/hooks/pre-commit-checks.ts +1 -1
- package/src/hooks/run-hooks.ts +2 -6
- package/src/hooks/shared-file.ts +3 -2
- package/src/hq/daemon-db.ts +8 -8
- package/src/hq/door.ts +3 -16
- package/src/hq/hq-db.ts +4 -3
- package/src/hq/hq-local.ts +1 -2
- package/src/hq/hq-store.ts +0 -15
- package/src/hq/item-direct.ts +8 -10
- package/src/hq/item-fill.ts +37 -0
- package/src/hq/kinds/item-gone.ts +7 -10
- package/src/hq/kinds/item-msg.ts +12 -18
- package/src/hq/kinds/item.ts +13 -19
- package/src/hq/kinds/report.ts +3 -4
- package/src/hq/owner-switch.ts +3 -3
- package/src/hq/report.ts +5 -9
- package/src/hq/switch.ts +2 -11
- package/src/hq/thread-sync.ts +5 -17
- package/src/hq/{shapes-words.ts → threads-words.ts} +2 -12
- package/src/http/owner-word.ts +1 -1
- package/src/identities/machine.ts +16 -0
- package/src/init-repo.ts +0 -1
- package/src/ledger/check-stats.ts +6 -5
- package/src/ledger/db.ts +2 -4
- package/src/ledger/record-kept.ts +117 -48
- package/src/ledger/run-log.ts +21 -2
- package/src/ledger/slow-tests.ts +96 -0
- package/src/ledger/store.ts +3 -86
- package/src/ledger/suite-log.ts +8 -2
- package/src/media-store/backup/facts.ts +3 -37
- package/src/media-store/backup/keys.ts +1 -8
- package/src/media-store/backup/manifest.ts +6 -67
- package/src/media-store/backup/restore.ts +4 -13
- package/src/media-store/backup/retention.ts +13 -1
- package/src/media-store/backup/run.ts +6 -267
- package/src/media-store/backup/snapshot.ts +2 -38
- package/src/media-store/backup/sources.ts +3 -113
- package/src/media-store/backup/target-send.ts +5 -29
- package/src/media-store/db.ts +8 -7
- package/src/media-store/forget-one.ts +1 -1
- package/src/media-store/forget.ts +1 -80
- package/src/orchestrator/guards.ts +0 -1
- package/src/orchestrator/presence.ts +2 -2
- package/src/orchestrator/routes.ts +1 -1
- package/src/orchestrator/started.ts +0 -9
- package/src/orchestrator/talk-key.ts +3 -4
- package/src/orchestrator/unheard.ts +1 -1
- package/src/plan/planner.ts +3 -2
- package/src/recordings/edit.ts +3 -3
- package/src/recordings/marks-draw.ts +17 -6
- package/src/recordings/marks.ts +120 -9
- package/src/reflections/reflections-queue.ts +3 -10
- package/src/release/notes.ts +1 -1
- package/src/release/public-clean.ts +66 -6
- package/src/release/run-bump.ts +11 -0
- package/src/release/run-release.ts +4 -0
- package/src/releases/from-thread.ts +3 -3
- package/src/releases/model.ts +186 -36
- package/src/releases/store.ts +13 -3
- package/src/releases/validate.ts +83 -0
- package/src/repo-config.ts +36 -64
- package/src/review/answer-kinds.ts +63 -4
- package/src/review/blocked-guard.ts +11 -0
- package/src/review/blocked-object.ts +298 -0
- package/src/review/cells.ts +144 -230
- package/src/review/close.ts +39 -1
- package/src/review/doc-save.ts +3 -2
- package/src/review/draft-item.ts +1 -1
- package/src/review/events.ts +3 -7
- package/src/review/expect.ts +23 -39
- package/src/review/format.ts +79 -46
- package/src/review/glyphs.ts +1 -0
- package/src/review/hand-over.ts +3 -3
- package/src/review/heard.ts +1 -1
- package/src/review/holds-sync.ts +2 -1
- package/src/review/inbox-hook.ts +2 -2
- package/src/review/inbox-read.ts +39 -33
- package/src/review/instruction-guards.ts +12 -0
- package/src/review/instructions.ts +0 -1
- package/src/review/item-db.ts +13 -43
- package/src/review/item-hq.ts +2 -2
- package/src/review/item-rows.ts +3 -14
- package/src/review/kind-catalog.ts +3 -1
- package/src/review/kinds.ts +18 -8
- package/src/review/live-view.ts +3 -0
- package/src/review/media-kind.ts +1 -1
- package/src/review/mentions.ts +1 -2
- package/src/review/model.ts +158 -114
- package/src/review/move.ts +149 -0
- package/src/review/need-threads.ts +3 -2
- package/src/review/object-card.ts +11 -0
- package/src/review/object-read.ts +6 -1
- package/src/review/one-block.ts +1 -1
- package/src/review/owner-read.ts +1 -1
- package/src/review/phone-push.ts +10 -9
- package/src/review/previews.ts +32 -4
- package/src/review/push.ts +2 -2
- package/src/review/recap.ts +129 -0
- package/src/review/referring.ts +6 -3
- package/src/review/reflection-object.ts +4 -3
- package/src/review/routes.ts +51 -47
- package/src/review/secret-route.ts +3 -2
- package/src/review/settle.ts +0 -6
- package/src/review/snooze.ts +5 -3
- package/src/review/speaker.ts +68 -0
- package/src/review/start-title.ts +19 -0
- package/src/review/store-parties.ts +28 -0
- package/src/review/store.ts +94 -59
- package/src/review/{wakes.ts → thread-events.ts} +92 -7
- package/src/review/thread-md.ts +35 -14
- package/src/review/thread-state.ts +804 -0
- package/src/review/threads.ts +29 -347
- package/src/review/traces.ts +104 -7
- package/src/review/trailer-item.ts +1 -1
- package/src/review/unit.ts +7 -9
- package/src/review/verdict-items.ts +12 -10
- package/src/review/view-layout.ts +25 -1
- package/src/review/watch-feed.ts +1 -2
- package/src/review/working-guards.ts +2 -3
- package/src/rules/untrack-generated.ts +1 -15
- package/src/secrets/copy.ts +4 -4
- package/src/secrets/lapse.ts +2 -1
- package/src/serve/hub-app/advisor-app.tsx +4 -4
- package/src/serve/hub-app/advisor-face.tsx +9 -3
- package/src/serve/hub-app/advisor-host.ts +27 -27
- package/src/serve/hub-app/advisors-model.ts +17 -8
- package/src/serve/hub-app/advisors-rights.tsx +1 -1
- package/src/serve/hub-app/advisors-st.ts +15 -14
- package/src/serve/hub-app/advisors-view.tsx +13 -11
- package/src/serve/hub-app/app-bridge.ts +23 -3
- package/src/serve/hub-app/asks-page.tsx +1 -1
- package/src/serve/hub-app/auto-text.tsx +71 -16
- package/src/serve/hub-app/check-view.tsx +0 -8
- package/src/serve/hub-app/controls.css +14 -3
- package/src/serve/hub-app/database-view.tsx +1 -2
- package/src/serve/hub-app/dock-st.ts +1 -1
- package/src/serve/hub-app/git-view.tsx +3 -1
- package/src/serve/hub-app/hub.css +12 -5
- package/src/serve/hub-app/icons.tsx +1 -1
- package/src/serve/hub-app/inbox-view.tsx +1 -2
- package/src/serve/hub-app/live-sources.ts +2 -2
- package/src/serve/hub-app/main-panel.tsx +2 -1
- package/src/serve/hub-app/panel-repo.ts +0 -9
- package/src/serve/hub-app/pic.tsx +29 -12
- package/src/serve/hub-app/polled.ts +16 -2
- package/src/serve/hub-app/recordings-st.ts +23 -2
- package/src/serve/hub-app/recordings-view.tsx +68 -10
- package/src/serve/hub-app/ref-pill.ts +1 -1
- package/src/serve/hub-app/repo-st.ts +1 -2
- package/src/serve/hub-app/review/advisor-add.tsx +1 -1
- package/src/serve/hub-app/review/advisor-invite.tsx +1 -1
- package/src/serve/hub-app/review/draft-body.tsx +2 -2
- package/src/serve/hub-app/review/heard-line.tsx +1 -1
- package/src/serve/hub-app/review/instructions-view.tsx +1 -8
- package/src/serve/hub-app/review/kind-states.tsx +14 -9
- package/src/serve/hub-app/review/kit.tsx +4 -11
- package/src/serve/hub-app/review/lane-bar.tsx +3 -3
- package/src/serve/hub-app/review/lightbox.tsx +15 -11
- package/src/serve/hub-app/review/line-window.ts +4 -1
- package/src/serve/hub-app/review/live-bar-st.ts +2 -2
- package/src/serve/hub-app/review/live-view.tsx +57 -1
- package/src/serve/hub-app/review/object-panel.tsx +20 -8
- package/src/serve/hub-app/review/question-views.tsx +191 -53
- package/src/serve/hub-app/review/recap-bar.tsx +40 -0
- package/src/serve/hub-app/review/request-cell.tsx +48 -0
- package/src/serve/hub-app/review/review-cells.tsx +154 -96
- package/src/serve/hub-app/review/review-host.ts +8 -4
- package/src/serve/hub-app/review/review-kit.ts +17 -11
- package/src/serve/hub-app/review/review-list.tsx +30 -35
- package/src/serve/hub-app/review/review-st.ts +32 -42
- package/src/serve/hub-app/review/review-thread.tsx +139 -85
- package/src/serve/hub-app/review/review-views.tsx +127 -68
- package/src/serve/hub-app/review/share-lines.tsx +4 -4
- package/src/serve/hub-app/review/start-st.ts +2 -5
- package/src/serve/hub-app/review/superseded-runs.ts +4 -3
- package/src/serve/hub-app/review/thread-close.tsx +10 -7
- package/src/serve/hub-app/review/thread-st.ts +381 -202
- package/src/serve/hub-app/review/tone-bar.tsx +129 -0
- package/src/serve/hub-app/review/tones.ts +53 -0
- package/src/serve/hub-app/review/trailer-body.tsx +2 -2
- package/src/serve/hub-app/review/trailer-st.ts +3 -2
- package/src/serve/hub-app/review/trailer-voices-st.ts +3 -2
- package/src/serve/hub-app/review.css +189 -106
- package/src/serve/hub-app/search-view.tsx +1 -1
- package/src/serve/hub-app/social/social-model.ts +0 -4
- package/src/serve/hub-app/source-acts.ts +2 -1
- package/src/serve/hub-app/stores/stores-page.tsx +2 -2
- package/src/serve/hub-app/terminal-sources.tsx +2 -1
- package/src/serve/hub-app/thread-row.tsx +3 -4
- package/src/serve/hub-app/tree-build.ts +0 -4
- package/src/serve/hub-app/urls-view.tsx +2 -1
- package/src/serve/hub-app/view-layout.css +13 -3
- package/src/serve/hub-app/wikis-view.tsx +5 -2
- package/src/serve/hub-runtime.ts +7 -37
- package/src/serve/project-gutter-route.ts +6 -2
- package/src/serve/read-thread.ts +20 -2
- package/src/serve/read-worker.ts +9 -1
- package/src/serve/record-pages.ts +46 -0
- package/src/serve/serve-hub.ts +2 -2
- package/src/serve/terminal-host.ts +1 -1
- package/src/serve/terminal-route.ts +1 -3
- package/src/serve/tracked-watch.ts +1 -3
- package/src/setup-house.ts +2 -2
- package/src/shipkit-files.ts +1 -1
- package/src/shipkit.ts +1 -6
- package/src/shot/client.ts +2 -1
- package/src/shot/film-box.ts +0 -20
- package/src/shot/on-place.ts +141 -0
- package/src/social/drafts.ts +1 -1
- package/src/social/kinds.ts +6 -29
- package/src/social/load.ts +2 -2
- package/src/social/post-object.ts +3 -2
- package/src/social/release-stage.ts +1 -1
- package/src/social/stage.ts +2 -2
- package/src/stores/model.ts +4 -0
- package/src/stores/routes.ts +11 -3
- package/src/suite/judge-suites.ts +58 -0
- package/src/suite/red-alone.ts +54 -18
- package/src/suite/runner-shapes.ts +2 -2
- package/src/suite/suite-cli.ts +67 -14
- package/src/suite/test-units.ts +2 -1
- package/src/urls/fill.ts +1 -1
- package/src/urls/places.ts +1 -2
- package/src/vault/vault-config.ts +2 -2
- package/src/vault/vault-init.ts +1 -5
- package/src/wiki/graph-page.ts +14 -2
- package/src/advisors/copy-truth.ts +0 -49
- package/src/advisors/door-child.ts +0 -112
- package/src/advisors/door-serve.ts +0 -52
- package/src/advisors/door.ts +0 -118
- package/src/checks/SK016-legacy-check-shapes.check.ts +0 -189
- package/src/checks/SK029-explicit-check-files.check.ts +0 -112
- package/src/checks/SK048-one-local-file.check.ts +0 -36
- package/src/core/config-rewrite.ts +0 -111
- package/src/core/daemon-port.ts +0 -10
- package/src/core/legacy-shapes.ts +0 -263
- package/src/core/migrate-layout.ts +0 -638
- package/src/core/port-check-cli.ts +0 -52
- package/src/core/port-check-file.ts +0 -295
- package/src/core/port-check-files.ts +0 -31
- package/src/gate/discover-legacy-checks.ts +0 -26
- package/src/home/home-move.ts +0 -527
- package/src/home/machine-fold.ts +0 -810
- package/src/hq/item-shapes.ts +0 -54
- package/src/hq/kinds/items-read.ts +0 -4
- package/src/media-store/backup/daemon.ts +0 -220
- package/src/media-store/backup/kept.ts +0 -241
- package/src/media-store/backup/prune.ts +0 -359
- package/src/media-store/backup/secret.ts +0 -88
- package/src/media-store/backup/ssh-space.ts +0 -202
- package/src/media-store/backup/watch.ts +0 -117
- package/src/review/band.ts +0 -182
- package/src/review/folders.ts +0 -216
- package/src/review/hook-ask.ts +0 -58
- package/src/review/role.ts +0 -48
- package/src/review/thread-fold.ts +0 -64
- package/src/review/wait.ts +0 -91
- package/src/rules/rule.ts +0 -43
- package/src/serve/hook-thread.ts +0 -37
- package/src/serve/hook-work.ts +0 -92
- package/src/serve/hook-worker.ts +0 -57
- package/src/serve/hub-app/review/dock.tsx +0 -147
- package/src/serve/hub-app/review/faces.tsx +0 -18
- package/src/serve/hub-app/review/item-verdict.tsx +0 -112
- package/src/serve/hub-app/review/review-board.tsx +0 -48
- /package/src/{scaffold → core}/jsonc-spans.ts +0 -0
|
@@ -1,27 +1,29 @@
|
|
|
1
|
-
// what the
|
|
2
|
-
// view and list row, built by the hub's builders from the projected items (project.ts projectItems), then
|
|
3
|
-
// second whitelist on the OUTPUT. The builders
|
|
4
|
-
// a trace), so every key of every
|
|
5
|
-
// an id of the
|
|
1
|
+
// what the users' port serves an advisor of one share (wiki tools/shipkit/advisors.md, The advisor's app): the hub's own
|
|
2
|
+
// thread view and list row, built by the hub's builders from the projected items (project.ts projectItems), then
|
|
3
|
+
// through a second whitelist on the OUTPUT. The builders take whole objects and write words the scan never saw (a
|
|
4
|
+
// cell's summary, a trace), so every key of every object that leaves is named here with its rule, and every string
|
|
5
|
+
// leaf is scanned words, an id of the view, a picture's served name, a time, or a short word, nothing else
|
|
6
6
|
// the one constraint a reader breaks first: a type that gains a key fails to compile until its table names it
|
|
7
|
-
// (`Rules<T>` asks every key), and a value its rule refuses leaves as nothing, a fault the
|
|
7
|
+
// (`Rules<T>` asks every key), and a value its rule refuses leaves as nothing, a fault the port logs and the owner's pass reports
|
|
8
8
|
import type { Cursor } from '../review/traces.ts'
|
|
9
|
-
import {
|
|
9
|
+
import { personState, type Closed, type OwnerWaiting, type ThreadState } from '../review/thread-state.ts'
|
|
10
|
+
import { listIndexOf, pageOf, queryOf, threadIndex, threadView, type ThreadPage, type Cell, type ReplyCell, type ThreadRow, type ThreadView, type VerdictCell, type VersionCell, type NoteCell, type EventCell } from '../review/cells.ts'
|
|
10
11
|
import type { Item, ReviewScene, ReviewView, Verdict } from '../review/model.ts'
|
|
11
12
|
import { membersOf, threadsOf, type Thread } from '../review/threads.ts'
|
|
12
13
|
import { traceWords, type Trace } from '../review/traces.ts'
|
|
13
14
|
import type { ProjectedItems } from './project.ts'
|
|
14
15
|
import { mask, maskHits, type ScanContext } from './scan.ts'
|
|
16
|
+
import { CODE_RE } from '../review/thread-code.ts'
|
|
15
17
|
|
|
16
|
-
/** how one key leaves: `text` scanned (a hit hidden), `id` an id of the
|
|
17
|
-
*
|
|
18
|
+
/** how one key leaves: `text` scanned (a hit hidden), `id` an id of the view, `file` a served picture, `address` the
|
|
19
|
+
* view's one address, `token` a short word (an enum) scanned too, `time`, `num`, `bool`, `drop` never; or a function */
|
|
18
20
|
type Rule = 'text' | 'id' | 'file' | 'address' | 'token' | 'time' | 'num' | 'bool' | 'drop' | ((v: unknown, o: Out) => unknown)
|
|
19
21
|
/** a rule for EVERY key of `T`, optional ones included: a new key fails to compile until it is named */
|
|
20
22
|
type Rules<T> = { [K in keyof Required<T>]: Rule }
|
|
21
23
|
|
|
22
24
|
export interface Out {
|
|
23
25
|
scan: ScanContext
|
|
24
|
-
/** each value a rule refused, by its path: a builder wrote what the
|
|
26
|
+
/** each value a rule refused, by its path: a builder wrote what the view must not hold */
|
|
25
27
|
faults: string[]
|
|
26
28
|
/** each text a hit was hidden in, by its path */
|
|
27
29
|
hidden: string[]
|
|
@@ -99,9 +101,9 @@ const always =
|
|
|
99
101
|
x
|
|
100
102
|
|
|
101
103
|
const SIZE = table<{ w: number; h: number }>({ w: 'num', h: 'num' })
|
|
102
|
-
/** a thread's short code (review/thread-code.ts)
|
|
103
|
-
*
|
|
104
|
-
const CODE =
|
|
104
|
+
/** a thread's short code (review/thread-code.ts): the owner's, of his repo's ids, given to advisorThread (the view's ids
|
|
105
|
+
* are others), so both say « #m6rz » of one thread; a hash of ids, no word of the store */
|
|
106
|
+
const CODE = (v: unknown, o: Out): unknown => (typeof v === 'string' && (v === '' || CODE_RE.test(v)) ? v : leaf('num', v, o))
|
|
105
107
|
/** a panorama kept: an advisor looks around it as the owner does. A splat or a mesh is dropped, its 3D file never
|
|
106
108
|
* sent: the advisor sees its poster */
|
|
107
109
|
const SCENE = (s: unknown): ReviewScene | undefined => (s !== null && typeof s === 'object' && (s as ReviewScene).kind === 'pano' ? { kind: 'pano' } : undefined)
|
|
@@ -159,7 +161,7 @@ const ITEM: Rules<Item> = {
|
|
|
159
161
|
doc: table<NonNullable<Item['doc']>>({ kind: 'token', text: 'text' }),
|
|
160
162
|
}
|
|
161
163
|
|
|
162
|
-
const TRACE: Rules<Trace> = { act: 'token', did: 'text', object: table({ cell: 'id', label: 'text' }), until: 'time', action: 'drop' }
|
|
164
|
+
const TRACE: Rules<Trace> = { act: 'token', did: 'text', object: table({ cell: 'id', label: 'text' }), until: 'time', action: 'drop', live: 'bool' }
|
|
163
165
|
|
|
164
166
|
/** the keys every cell kind shares: no session, no heard mark, no lane (an agent is « agent ») */
|
|
165
167
|
const BASE = {
|
|
@@ -167,10 +169,10 @@ const BASE = {
|
|
|
167
169
|
id: 'id',
|
|
168
170
|
on: 'id',
|
|
169
171
|
at: 'time',
|
|
170
|
-
// the reader's own words (a pick of theirs that answered a question) are theirs
|
|
172
|
+
// the reader's own words (a pick of theirs that answered a question) are theirs in their view, never an agent's
|
|
171
173
|
who: (v: unknown) => (v === 'owner' ? 'owner' : v === 'player' || v === 'advisor' ? 'advisor' : 'agent'),
|
|
172
174
|
session: 'drop',
|
|
173
|
-
// a person's name on their own words: never
|
|
175
|
+
// a person's name on their own words: never in another person's view
|
|
174
176
|
advisor: 'drop',
|
|
175
177
|
party: 'token',
|
|
176
178
|
summary: 'text',
|
|
@@ -196,31 +198,36 @@ const REPLY: Rules<ReplyCell> = {
|
|
|
196
198
|
options: list('text'),
|
|
197
199
|
pick: 'num',
|
|
198
200
|
views: (v, o) => (Array.isArray(v) ? v.map((x, i) => (x === null ? null : leaf('num', x, at(o, i)) ?? null)) : undefined),
|
|
199
|
-
answered: table({ option: 'num', text: 'text', at: 'time', by: 'drop' }),
|
|
201
|
+
answered: table({ option: 'num', text: 'text', remark: 'text', at: 'time', by: 'drop' }),
|
|
200
202
|
open: 'bool',
|
|
201
203
|
ownerPick: 'num',
|
|
202
|
-
// only the reader's own pick reaches a
|
|
204
|
+
// only the reader's own pick reaches a view (advisors/project.ts): its name and id stay empty
|
|
203
205
|
people: list(table({ option: 'num', name: always(''), advisor: always(''), photo: 'drop', you: 'bool', answer: 'bool' })),
|
|
204
206
|
lines: 'drop',
|
|
205
207
|
choices: 'drop',
|
|
206
208
|
value: 'drop',
|
|
207
209
|
secret: 'drop',
|
|
208
210
|
none: 'text',
|
|
211
|
+
tone: 'token',
|
|
212
|
+
row: table({ group: 'token', i: 'num', n: 'num', label: 'text' }),
|
|
209
213
|
}),
|
|
210
214
|
propose: table<NonNullable<ReplyCell['propose']>>({
|
|
211
215
|
on: 'drop',
|
|
212
216
|
fields: list(table({ key: 'text', before: 'text', after: 'text', type: 'token', lang: 'drop', view: 'drop', applied: table({ text: 'text', at: 'time' }) })),
|
|
213
217
|
open: 'bool',
|
|
218
|
+
none: 'text',
|
|
214
219
|
page: 'drop',
|
|
215
220
|
}),
|
|
216
221
|
action: 'drop',
|
|
217
222
|
long: 'drop',
|
|
223
|
+
recap: 'bool',
|
|
224
|
+
recapAsk: 'bool',
|
|
218
225
|
edit: table({ of: 'id', diff: list('text') }),
|
|
219
226
|
moot: 'bool',
|
|
220
227
|
answers: 'id',
|
|
221
228
|
judge: table<NonNullable<ReplyCell['judge']>>({ open: 'bool', verdict: table({ id: 'id', status: 'token', text: 'text', at: 'time' }) }),
|
|
222
229
|
about: 'drop',
|
|
223
|
-
//
|
|
230
|
+
// the owner's word that names this advisor: `you`, the one word the view keeps (advisors/project.ts)
|
|
224
231
|
to: list('token'),
|
|
225
232
|
instructions: 'drop',
|
|
226
233
|
step: 'drop',
|
|
@@ -263,13 +270,8 @@ const VIEW: Rules<ThreadView> = {
|
|
|
263
270
|
topic: 'drop',
|
|
264
271
|
lane: 'drop',
|
|
265
272
|
origin: ORIGIN,
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
move: 'token',
|
|
269
|
-
waits: 'bool',
|
|
270
|
-
next: 'drop',
|
|
271
|
-
active: 'bool',
|
|
272
|
-
rework: always(null),
|
|
273
|
+
state: (v, o) => pick(v as ThreadState, STATE, o),
|
|
274
|
+
headState: table({ state: 'token', why: 'token', topic: 'drop', worker: 'drop', since: 'drop' }),
|
|
273
275
|
verdict: table(VERDICT_HEAD),
|
|
274
276
|
versions: 'num',
|
|
275
277
|
forks: always([]),
|
|
@@ -279,18 +281,39 @@ const VIEW: Rules<ThreadView> = {
|
|
|
279
281
|
missing: always([]),
|
|
280
282
|
coming: always([]),
|
|
281
283
|
drafts: always([]),
|
|
284
|
+
// the fold before a recap: their copy draws every message, its cells their own ids
|
|
285
|
+
recap: 'drop',
|
|
282
286
|
ask: 'drop',
|
|
283
|
-
aside: 'drop',
|
|
284
287
|
muted: 'drop',
|
|
288
|
+
cells: list(cellOut),
|
|
289
|
+
}
|
|
290
|
+
|
|
291
|
+
/** the thread's state as the person may know it: whose turn and what waits, never who holds it, works it or owes it */
|
|
292
|
+
const STATE: Rules<ThreadState> = {
|
|
285
293
|
turn: 'token',
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
294
|
+
closed: (v, o) => (v === null ? null : pick(v as Closed, { at: 'time', by: 'token', who: always(''), why: 'token' }, o)),
|
|
295
|
+
status: 'token',
|
|
296
|
+
headWaits: 'bool',
|
|
297
|
+
waitsOwner: list(table<OwnerWaiting>({ wait: 'token', on: 'drop', id: 'id', what: 'token', title: 'drop', n: 'num', step: 'bool' })),
|
|
298
|
+
wait: 'token',
|
|
299
|
+
waitsOn: 'drop',
|
|
300
|
+
owed: 'token',
|
|
301
|
+
verbs: list('token'),
|
|
302
|
+
owes: always([]),
|
|
303
|
+
unanswered: always(null),
|
|
304
|
+
active: 'bool',
|
|
305
|
+
validated: 'bool',
|
|
306
|
+
holder: always(null),
|
|
307
|
+
working: always(null),
|
|
308
|
+
next: always(null),
|
|
309
|
+
laneAsk: always(null),
|
|
310
|
+
aside: always(null),
|
|
292
311
|
holds: always([]),
|
|
293
|
-
|
|
312
|
+
ask: always(null),
|
|
313
|
+
recap: always(null),
|
|
314
|
+
cursor: (v, o) => (v === null ? null : CURSOR(v, o)),
|
|
315
|
+
updated: 'time',
|
|
316
|
+
works: 'bool',
|
|
294
317
|
}
|
|
295
318
|
|
|
296
319
|
const ROW: Rules<ThreadRow> = {
|
|
@@ -306,8 +329,6 @@ const ROW: Rules<ThreadRow> = {
|
|
|
306
329
|
origin: (v) => (v === 'agent' || v === 'auto' ? 'agent' : 'owner'),
|
|
307
330
|
rule: 'drop',
|
|
308
331
|
session: 'drop',
|
|
309
|
-
status: 'token',
|
|
310
|
-
move: 'token',
|
|
311
332
|
versions: 'num',
|
|
312
333
|
views: 'num',
|
|
313
334
|
thumb: 'file',
|
|
@@ -316,29 +337,30 @@ const ROW: Rules<ThreadRow> = {
|
|
|
316
337
|
choice: 'bool',
|
|
317
338
|
wip: always(false),
|
|
318
339
|
update: 'drop',
|
|
319
|
-
waits: 'bool',
|
|
320
|
-
next: 'drop',
|
|
321
|
-
active: 'bool',
|
|
322
340
|
unread: always(false),
|
|
323
|
-
rework: always(null),
|
|
324
341
|
ids: list('id'),
|
|
325
|
-
|
|
326
|
-
wait: 'token',
|
|
327
|
-
waitsOn: 'drop',
|
|
328
|
-
owed: 'token',
|
|
329
|
-
verbs: list('token'),
|
|
330
|
-
aside: 'drop',
|
|
331
|
-
holder: 'drop',
|
|
332
|
-
cursor: CURSOR,
|
|
333
|
-
working: 'drop',
|
|
334
|
-
workingAt: 'drop',
|
|
335
|
-
laneAsk: 'drop',
|
|
336
|
-
validated: 'bool',
|
|
342
|
+
state: (v, o) => pick(v as ThreadState, STATE, o),
|
|
337
343
|
addresses: always([]),
|
|
338
|
-
// who else can open the thread: never another advisor's name or face
|
|
344
|
+
// who else can open the thread: never another advisor's name or face on the advisors page
|
|
339
345
|
advisors: 'drop',
|
|
340
346
|
}
|
|
341
347
|
|
|
348
|
+
/** a row a person may see, with the words their search reads of it */
|
|
349
|
+
export type PersonEntry = { row: ThreadRow; text: string }
|
|
350
|
+
|
|
351
|
+
/** the person's list as the owner's hub pages his: its order, its search (words, `#code`), its filters, its counts,
|
|
352
|
+
* what moved since their last act */
|
|
353
|
+
export const personPage = (rows: readonly PersonEntry[], q: URLSearchParams, since: ThreadPage['since'] = null): ThreadPage => pageOf(listIndexOf(rows, since), queryOf(q))
|
|
354
|
+
|
|
355
|
+
/** what moved since the person's last act (`left`: a word, a pick, a verdict, a thread they started; never a read, which
|
|
356
|
+
* the page marks as it opens), as his hub's line reads his (thread-state.ts sinceHeLeft): the threads anyone but them
|
|
357
|
+
* wrote in since, and how many are their turn. Null before their first act */
|
|
358
|
+
export function personSince(read: readonly { row: ThreadRow; view: ThreadView }[], left: string | null): ThreadPage['since'] {
|
|
359
|
+
if (left === null) return null
|
|
360
|
+
const moved = read.filter((x) => x.view.cells.some((c) => c.who !== 'advisor' && c.at > left && !(c.kind === 'event' && c.trace?.act === 'read')))
|
|
361
|
+
return { at: left, moved: moved.length, yours: moved.filter((x) => x.row.state.turn === 'yours').length }
|
|
362
|
+
}
|
|
363
|
+
|
|
342
364
|
/** the view's whitelist, for a test that a key of the type is named */
|
|
343
365
|
export const ADVISOR_VIEW_KEYS = { view: Object.keys(VIEW), row: Object.keys(ROW), item: Object.keys(ITEM), reply: Object.keys(REPLY) }
|
|
344
366
|
|
|
@@ -349,9 +371,9 @@ export interface AdvisorThread {
|
|
|
349
371
|
hidden: string[]
|
|
350
372
|
}
|
|
351
373
|
|
|
352
|
-
/** an agent's read as the person reads it: « your » is theirs
|
|
353
|
-
* (an id of the
|
|
354
|
-
* names
|
|
374
|
+
/** an agent's read as the person reads it: « your » is theirs on the advisors page, never the owner's. A read of their
|
|
375
|
+
* own words (an id of the view no message holds: projectItems) links their word's cell (`own`, by that id); a read of
|
|
376
|
+
* the owner's names the owner. Run once the person's own cells are in the view (sync.ts prepare) */
|
|
355
377
|
export function personReads(view: ThreadView, items: ProjectedItems['items'], o: { owner: string; own: ReadonlyMap<string, string> }): void {
|
|
356
378
|
const msgs = new Map<string, { x: ProjectedItems['items'][number]; m: ProjectedItems['items'][number]['thread'][number] }>(items.flatMap((x) => x.thread.map((m) => [`${x.item.id}/${m.id}`, { x, m }] as const)))
|
|
357
379
|
view.cells = view.cells.map((c) => {
|
|
@@ -411,19 +433,19 @@ export function namesOf(view: ThreadView, row: ThreadRow, items: ProjectedItems[
|
|
|
411
433
|
}
|
|
412
434
|
for (const x of [view, row]) {
|
|
413
435
|
add(x.lane)
|
|
414
|
-
add(x.holder?.lane)
|
|
415
|
-
add(x.holder?.session)
|
|
416
|
-
add(x.cursor?.who)
|
|
417
|
-
add(x.cursor?.session)
|
|
418
|
-
add(x.
|
|
419
|
-
add(x.working)
|
|
420
|
-
add(x.laneAsk?.to)
|
|
421
|
-
add(x.laneAsk?.toSession)
|
|
422
|
-
|
|
436
|
+
add(x.state.holder?.lane)
|
|
437
|
+
add(x.state.holder?.session)
|
|
438
|
+
add(x.state.cursor?.who)
|
|
439
|
+
add(x.state.cursor?.session)
|
|
440
|
+
add(x.state.working?.who)
|
|
441
|
+
add(x.state.working?.session)
|
|
442
|
+
add(x.state.laneAsk?.to)
|
|
443
|
+
add(x.state.laneAsk?.toSession)
|
|
444
|
+
for (const o of x.state.owes) if (o.kind === 'rework') add(o.lane)
|
|
423
445
|
}
|
|
424
446
|
add(row.rule)
|
|
425
447
|
add(row.session)
|
|
426
|
-
add(view.
|
|
448
|
+
add(view.headState.worker)
|
|
427
449
|
for (const c of view.cells) {
|
|
428
450
|
add(c.who)
|
|
429
451
|
add(c.session)
|
|
@@ -438,28 +460,52 @@ export function namesOf(view: ThreadView, row: ThreadRow, items: ProjectedItems[
|
|
|
438
460
|
}
|
|
439
461
|
|
|
440
462
|
/** the thread as the advisor's page reads it: the hub's view and row of the projected items, by the output whitelist.
|
|
441
|
-
* `null` when the
|
|
442
|
-
/** `
|
|
443
|
-
*
|
|
444
|
-
|
|
463
|
+
* `null` when the view holds nothing of the thread */
|
|
464
|
+
/** `code`: the thread's code in the owner's store (review/store.ts threadCodeOf), the one his hub shows; `works`: a
|
|
465
|
+
* live agent works it now, as his hub's band reads it of his parties (thread-state.ts bandOf) */
|
|
466
|
+
/** `cursor`: where the owner's newest word stands in the store's own thread (review/traces.ts cursorOf): the projection
|
|
467
|
+
* holds no read mark, so the view takes it from there, its agent unnamed */
|
|
468
|
+
export function advisorThread(
|
|
469
|
+
p: Pick<ProjectedItems, 'items' | 'head'> & Partial<Pick<ProjectedItems, 'title' | 'numbers' | 'headKept'>>,
|
|
470
|
+
o: { scan: ScanContext; now: Date; owner: string; cursor?: Cursor | null; names?: readonly string[]; real?: ThreadState; deferred?: boolean; code?: string; works?: boolean },
|
|
471
|
+
): AdvisorThread | null {
|
|
445
472
|
const threads = threadsOf(p.items)
|
|
446
473
|
const t = threads.find((x) => x.versions.some((v) => v.item.id === p.head) || x.answers.some((a) => a.item.id === p.head)) ?? threads[0]
|
|
447
474
|
if (t === undefined) return null
|
|
448
|
-
|
|
449
|
-
|
|
450
|
-
|
|
475
|
+
const kept = p.headKept ?? true
|
|
476
|
+
// the thread as the person may know it, before the whitelist: its own title and version numbers, the real
|
|
477
|
+
// thread's state read for them (thread-state.ts personState), the store's cursor alone (the builders would read one
|
|
478
|
+
// off the agents' reads the view holds)
|
|
479
|
+
const view0 = threadView(t, p.items, threads, t.head.item.id, o.now)
|
|
480
|
+
const truth = <T extends { state: ThreadState; title: string; versions: number; code: string }>(x: T, top: number): T => ({
|
|
481
|
+
...x,
|
|
482
|
+
...(p.title !== undefined ? { title: p.title } : {}),
|
|
483
|
+
code: o.code ?? '',
|
|
484
|
+
...(top > 0 ? { versions: top } : {}),
|
|
485
|
+
state: { ...personState(o.real ?? x.state, x.state, { deferred: o.deferred ?? false, headKept: kept, works: o.works ?? false }), cursor: o.cursor ?? null },
|
|
486
|
+
})
|
|
487
|
+
let top = 0
|
|
488
|
+
const cells = view0.cells.map((c) => {
|
|
489
|
+
if (c.kind === 'version') {
|
|
490
|
+
const n = p.numbers?.get(c.item.id) ?? c.n
|
|
491
|
+
top = Math.max(top, n)
|
|
492
|
+
return { ...c, n }
|
|
493
|
+
}
|
|
494
|
+
return c.kind === 'verdict' ? { ...c, n: p.numbers?.get(c.on) ?? c.n } : c
|
|
495
|
+
})
|
|
496
|
+
const raw = truth({ ...view0, cells, ...(kept ? {} : { verdict: null }) }, top)
|
|
451
497
|
const ix = threadIndex(p.items, o.now)
|
|
452
498
|
const found = ix.entries.find((e) => e.t.head.item.id === t.head.item.id)?.row
|
|
453
499
|
if (found === undefined) return null
|
|
454
|
-
const rawRow =
|
|
500
|
+
const rawRow = truth(found, top)
|
|
455
501
|
const scan = { ...o.scan, words: [...o.scan.words, ...namesOf(raw, rawRow, p.items), ...(o.names ?? [])] }
|
|
456
502
|
const out: Out = { scan, faults: [], hidden: [], path: 'view' }
|
|
457
503
|
const view = pick(raw, VIEW, out)
|
|
458
504
|
const row = pick(rawRow, ROW, { ...out, path: 'row' })
|
|
459
505
|
if (view === undefined || row === undefined) return null
|
|
460
|
-
// a trace's words name the owner « you » in
|
|
506
|
+
// a trace's words name the owner « you » in the owner's hub: on the advisors page they name the owner, and the reader « you »
|
|
461
507
|
view.cells = view.cells.map((c) => (c.trace === undefined ? c : { ...c, summary: leaf('text', traceWords(c.who === 'owner' ? o.owner : c.who === 'advisor' ? 'you' : 'agent', c.trace), out) as string }))
|
|
462
508
|
// a thread's row and view stay one thread to the advisor even when the store held more than one chain
|
|
463
|
-
if (threads.length > 1) out.faults.push(`the
|
|
509
|
+
if (threads.length > 1) out.faults.push(`the view holds ${threads.length} threads, its head's alone is served`)
|
|
464
510
|
return { view, row, faults: out.faults, hidden: out.hidden }
|
|
465
511
|
}
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
// run time, each one a module the owner's hub reaches too, inside a short list of folders, and none of the home, the
|
|
3
3
|
// terminal, the vault or a secret. Type only imports are no import: the bundler drops them. Pure: the test and the
|
|
4
4
|
// build feed it the files
|
|
5
|
-
// the one constraint a reader breaks first: the
|
|
5
|
+
// the one constraint a reader breaks first: the users' port's route list is the wall; this keeps the page's code the hub's
|
|
6
6
|
// own thread components and nothing more, so a thread draws one way for both
|
|
7
7
|
import { builtinModules } from 'node:module'
|
|
8
8
|
import { posix } from 'node:path'
|
package/src/advisors/app.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
// the advisors' page as files (wiki tools/shipkit/advisors.md, The advisor's app): the hub's review page built for the
|
|
2
|
-
// advisor's role from advisor.html, one script and one stylesheet, each named by the sha256 of its bytes. The
|
|
3
|
-
// them
|
|
2
|
+
// advisor's role from advisor.html, one script and one stylesheet, each named by the sha256 of its bytes. The users'
|
|
3
|
+
// port builds them from this source (advisorBundle) and serves that pair alone
|
|
4
4
|
// the one constraint a reader breaks first: a graph the guard refuses never builds (app-graph.ts)
|
|
5
5
|
import { readFileSync, statSync } from 'node:fs'
|
|
6
6
|
import { join } from 'node:path'
|
|
@@ -16,8 +16,6 @@ export interface AppFile {
|
|
|
16
16
|
export interface AppBundle {
|
|
17
17
|
js: AppFile
|
|
18
18
|
css: AppFile
|
|
19
|
-
/** what the door's variable APP holds: `<js sha>.<css sha>` */
|
|
20
|
-
pin: string
|
|
21
19
|
}
|
|
22
20
|
|
|
23
21
|
const SRC = join(import.meta.dir, '..')
|
|
@@ -32,12 +30,6 @@ const disk: Read = (p) => {
|
|
|
32
30
|
|
|
33
31
|
const fileOf = (bytes: Bytes): AppFile => ({ sha: createHash('sha256').update(bytes).digest('hex'), bytes })
|
|
34
32
|
|
|
35
|
-
/** the pin APP holds, read back: null when it is not one */
|
|
36
|
-
export function pinOf(app: string | undefined): { js: string; css: string } | null {
|
|
37
|
-
const m = /^([0-9a-f]{64})\.([0-9a-f]{64})$/.exec(app ?? '')
|
|
38
|
-
return m === null ? null : { js: m[1]!, css: m[2]! }
|
|
39
|
-
}
|
|
40
|
-
|
|
41
33
|
/** every module the page holds and its time: the bundle builds again when one moves */
|
|
42
34
|
function stampOf(): string {
|
|
43
35
|
const files = [...graphOf(ADVISOR_ENTRY, disk).from.keys(), ADVISOR_HTML]
|
|
@@ -58,7 +50,7 @@ async function build(): Promise<AppBundle> {
|
|
|
58
50
|
}
|
|
59
51
|
const js = await of('.js')
|
|
60
52
|
const css = await of('.css')
|
|
61
|
-
return { js, css
|
|
53
|
+
return { js, css }
|
|
62
54
|
}
|
|
63
55
|
|
|
64
56
|
/** the page's two files, built once a process and again when a module of its graph moved */
|
package/src/advisors/cf-api.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
// the Cloudflare api as the advisors'
|
|
1
|
+
// the Cloudflare api as the advisors page's setup calls it (expose.ts): one token, a call's result or its errors thrown
|
|
2
2
|
// with the method and path
|
|
3
3
|
const API = 'https://api.cloudflare.com/client/v4'
|
|
4
4
|
|
|
@@ -1,6 +1,7 @@
|
|
|
1
|
-
//
|
|
2
|
-
//
|
|
3
|
-
// and renamed. The one constraint a reader breaks first: a
|
|
1
|
+
// a bucket as a folder on the hq Mac (wiki tools/shipkit/advisors.md, Who calls: the users' port): the users'
|
|
2
|
+
// port's folder `users/`, where the port writes what an advisor sends and the owner's pass sweeps it, and the copy's
|
|
3
|
+
// folder its first open reads. One file a key, written beside and renamed. The one constraint a reader breaks first: a
|
|
4
|
+
// key never leaves the folder (no `..`, no absolute path)
|
|
4
5
|
import { existsSync, mkdirSync, readdirSync, readFileSync, rmSync, writeFileSync } from 'node:fs'
|
|
5
6
|
import { dirname, join, relative, sep } from 'node:path'
|
|
6
7
|
import { atomicWrite } from '../core/atomic-write.ts'
|