@stringsync/splates 0.0.61 → 1.13.3
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/README.md +2 -2
- package/artifact.d.ts +2 -2
- package/blockers.d.ts +1 -1
- package/config.d.ts +12 -0
- package/config.js +0 -0
- package/creds.d.ts +2 -2
- package/evals.d.ts +2 -2
- package/flags.d.ts +4 -4
- package/handoff.d.ts +3 -4
- package/hook.d.ts +2 -2
- package/index.js +108 -108
- package/lane.d.ts +2 -2
- package/mirror.d.ts +14 -0
- package/mirror.js +22 -0
- package/package.json +12 -4
- package/projects.d.ts +2 -2
- package/queue.d.ts +2 -2
- package/replica.d.ts +2 -2
- package/server.d.ts +2 -2
- package/setup.d.ts +2 -2
- package/ship.d.ts +2 -2
- package/slots.d.ts +2 -2
- package/splates.d.ts +2 -2
- package/task.d.ts +2 -2
- package/tunnel.d.ts +2 -2
- package/vendor/@stringsync/splates-server/LICENSE +21 -0
- package/vendor/@stringsync/splates-server/age.d.ts +2 -0
- package/vendor/@stringsync/splates-server/agents/acp-extensions.d.ts +92 -0
- package/vendor/@stringsync/splates-server/agents/agents.d.ts +19 -0
- package/vendor/@stringsync/splates-server/agents/compaction.d.ts +17 -0
- package/vendor/@stringsync/splates-server/agents/connection.d.ts +191 -0
- package/vendor/@stringsync/splates-server/agents/errors.d.ts +8 -0
- package/vendor/@stringsync/splates-server/agents/fold.d.ts +45 -0
- package/vendor/@stringsync/splates-server/agents/index.d.ts +16 -0
- package/vendor/@stringsync/splates-server/agents/index.js +60 -0
- package/vendor/@stringsync/splates-server/agents/process.d.ts +67 -0
- package/vendor/@stringsync/splates-server/agents/scratch.d.ts +7 -0
- package/vendor/@stringsync/splates-server/agents/shared-browser.d.ts +47 -0
- package/vendor/@stringsync/splates-server/agents/start-lock.d.ts +24 -0
- package/vendor/@stringsync/splates-server/agents/stream.d.ts +91 -0
- package/vendor/@stringsync/splates-server/agents/tool-calls.d.ts +18 -0
- package/vendor/@stringsync/splates-server/agents/watch.d.ts +46 -0
- package/vendor/@stringsync/splates-server/agents/watched.d.ts +43 -0
- package/vendor/@stringsync/splates-server/artifacts/artifact.d.ts +33 -0
- package/vendor/@stringsync/splates-server/artifacts/artifacts.d.ts +162 -0
- package/vendor/@stringsync/splates-server/artifacts/attach.d.ts +31 -0
- package/vendor/@stringsync/splates-server/artifacts/attachments.d.ts +50 -0
- package/vendor/@stringsync/splates-server/artifacts/index.d.ts +8 -0
- package/vendor/@stringsync/splates-server/artifacts/index.js +38 -0
- package/vendor/@stringsync/splates-server/artifacts/room.d.ts +46 -0
- package/vendor/@stringsync/splates-server/artifacts/routes.d.ts +22 -0
- package/vendor/@stringsync/splates-server/artifacts/viewers.d.ts +6 -0
- package/vendor/@stringsync/splates-server/auto-pick/classes.d.ts +29 -0
- package/vendor/@stringsync/splates-server/auto-pick/classify.d.ts +60 -0
- package/vendor/@stringsync/splates-server/auto-pick/clef.d.ts +15 -0
- package/vendor/@stringsync/splates-server/auto-pick/decide.d.ts +78 -0
- package/vendor/@stringsync/splates-server/auto-pick/defaults.d.ts +3 -0
- package/vendor/@stringsync/splates-server/auto-pick/follow-up.d.ts +25 -0
- package/vendor/@stringsync/splates-server/auto-pick/index.d.ts +24 -0
- package/vendor/@stringsync/splates-server/auto-pick/jev.d.ts +38 -0
- package/vendor/@stringsync/splates-server/auto-pick/judge.d.ts +21 -0
- package/vendor/@stringsync/splates-server/auto-pick/judged.d.ts +33 -0
- package/vendor/@stringsync/splates-server/auto-pick/key.d.ts +6 -0
- package/vendor/@stringsync/splates-server/auto-pick/lift.d.ts +18 -0
- package/vendor/@stringsync/splates-server/auto-pick/queue.d.ts +30 -0
- package/vendor/@stringsync/splates-server/auto-pick/rank.d.ts +10 -0
- package/vendor/@stringsync/splates-server/auto-pick/record.d.ts +19 -0
- package/vendor/@stringsync/splates-server/auto-pick/routes.d.ts +25 -0
- package/vendor/@stringsync/splates-server/auto-pick/rule-names.d.ts +9 -0
- package/vendor/@stringsync/splates-server/auto-pick/rules-routes.d.ts +49 -0
- package/vendor/@stringsync/splates-server/auto-pick/rules.d.ts +97 -0
- package/vendor/@stringsync/splates-server/auto-pick/start.d.ts +79 -0
- package/vendor/@stringsync/splates-server/auto-pick/store.d.ts +25 -0
- package/vendor/@stringsync/splates-server/auto-pick/system-one.d.ts +60 -0
- package/vendor/@stringsync/splates-server/auto-pick/trial.d.ts +32 -0
- package/vendor/@stringsync/splates-server/board/backlog.d.ts +4 -0
- package/vendor/@stringsync/splates-server/board/blocked-warning.d.ts +7 -0
- package/vendor/@stringsync/splates-server/board/browser.d.ts +8 -0
- package/vendor/@stringsync/splates-server/board/change-lane.d.ts +12 -0
- package/vendor/@stringsync/splates-server/board/deferral.d.ts +87 -0
- package/vendor/@stringsync/splates-server/board/elsewhere-links.d.ts +26 -0
- package/vendor/@stringsync/splates-server/board/elsewhere.d.ts +119 -0
- package/vendor/@stringsync/splates-server/board/index.d.ts +21 -0
- package/vendor/@stringsync/splates-server/board/index.js +112 -0
- package/vendor/@stringsync/splates-server/board/lane.d.ts +69 -0
- package/vendor/@stringsync/splates-server/board/lanes-from-tags.d.ts +17 -0
- package/vendor/@stringsync/splates-server/board/lanes.d.ts +117 -0
- package/vendor/@stringsync/splates-server/board/routes.d.ts +54 -0
- package/vendor/@stringsync/splates-server/board/store.d.ts +74 -0
- package/vendor/@stringsync/splates-server/board/task-edit.d.ts +81 -0
- package/vendor/@stringsync/splates-server/board/task-file.d.ts +24 -0
- package/vendor/@stringsync/splates-server/board/task-journal.d.ts +9 -0
- package/vendor/@stringsync/splates-server/board/task-lanes.d.ts +95 -0
- package/vendor/@stringsync/splates-server/board/task-list.d.ts +40 -0
- package/vendor/@stringsync/splates-server/board/task.d.ts +301 -0
- package/vendor/@stringsync/splates-server/board/tasks.d.ts +172 -0
- package/vendor/@stringsync/splates-server/chunk-files-jkqj87yx.js +14 -0
- package/vendor/@stringsync/splates-server/chunk-maps-mnjqydx4.txt +1 -0
- package/vendor/@stringsync/splates-server/chunks-3jkzx1q9.txt +1 -0
- package/vendor/@stringsync/splates-server/comma-list.d.ts +2 -0
- package/vendor/@stringsync/splates-server/comma-list.js +6 -0
- package/vendor/@stringsync/splates-server/config/browser.d.ts +1 -0
- package/vendor/@stringsync/splates-server/config/config.d.ts +210 -0
- package/vendor/@stringsync/splates-server/config/index.d.ts +6 -0
- package/vendor/@stringsync/splates-server/config/index.js +42 -0
- package/vendor/@stringsync/splates-server/config/legacy-names.d.ts +70 -0
- package/vendor/@stringsync/splates-server/config/legacy-ps.d.ts +32 -0
- package/vendor/@stringsync/splates-server/config/load.d.ts +46 -0
- package/vendor/@stringsync/splates-server/config/source.d.ts +7 -0
- package/vendor/@stringsync/splates-server/config/type-config.d.ts +14 -0
- package/vendor/@stringsync/splates-server/conversations/answered.d.ts +7 -0
- package/vendor/@stringsync/splates-server/conversations/archive.d.ts +16 -0
- package/vendor/@stringsync/splates-server/conversations/background.d.ts +21 -0
- package/vendor/@stringsync/splates-server/conversations/browser.d.ts +12 -0
- package/vendor/@stringsync/splates-server/conversations/choice.d.ts +8 -0
- package/vendor/@stringsync/splates-server/conversations/compact.d.ts +6 -0
- package/vendor/@stringsync/splates-server/conversations/conversation.d.ts +420 -0
- package/vendor/@stringsync/splates-server/conversations/conversations.d.ts +181 -0
- package/vendor/@stringsync/splates-server/conversations/entry.d.ts +286 -0
- package/vendor/@stringsync/splates-server/conversations/events.d.ts +36 -0
- package/vendor/@stringsync/splates-server/conversations/files.d.ts +62 -0
- package/vendor/@stringsync/splates-server/conversations/given.d.ts +18 -0
- package/vendor/@stringsync/splates-server/conversations/heard.d.ts +8 -0
- package/vendor/@stringsync/splates-server/conversations/host.d.ts +176 -0
- package/vendor/@stringsync/splates-server/conversations/index.d.ts +22 -0
- package/vendor/@stringsync/splates-server/conversations/index.js +80 -0
- package/vendor/@stringsync/splates-server/conversations/listing.d.ts +15 -0
- package/vendor/@stringsync/splates-server/conversations/log.d.ts +117 -0
- package/vendor/@stringsync/splates-server/conversations/messages.d.ts +23 -0
- package/vendor/@stringsync/splates-server/conversations/name.d.ts +38 -0
- package/vendor/@stringsync/splates-server/conversations/options.d.ts +87 -0
- package/vendor/@stringsync/splates-server/conversations/outside.d.ts +14 -0
- package/vendor/@stringsync/splates-server/conversations/reference.d.ts +2 -0
- package/vendor/@stringsync/splates-server/conversations/routes.d.ts +109 -0
- package/vendor/@stringsync/splates-server/conversations/search.d.ts +15 -0
- package/vendor/@stringsync/splates-server/conversations/spent.d.ts +19 -0
- package/vendor/@stringsync/splates-server/conversations/state.d.ts +606 -0
- package/vendor/@stringsync/splates-server/conversations/stream.d.ts +34 -0
- package/vendor/@stringsync/splates-server/conversations/transcript.d.ts +9 -0
- package/vendor/@stringsync/splates-server/conversations/tree.d.ts +11 -0
- package/vendor/@stringsync/splates-server/conversations/turn-end.d.ts +30 -0
- package/vendor/@stringsync/splates-server/conversations/turns.d.ts +134 -0
- package/vendor/@stringsync/splates-server/conversations/updates.d.ts +21 -0
- package/vendor/@stringsync/splates-server/creds/creds.d.ts +86 -0
- package/vendor/@stringsync/splates-server/creds/index.d.ts +6 -0
- package/vendor/@stringsync/splates-server/creds/index.js +28 -0
- package/vendor/@stringsync/splates-server/creds/key-file.d.ts +21 -0
- package/vendor/@stringsync/splates-server/creds/requests.d.ts +54 -0
- package/vendor/@stringsync/splates-server/creds/routes.d.ts +16 -0
- package/vendor/@stringsync/splates-server/creds/stores.d.ts +37 -0
- package/vendor/@stringsync/splates-server/dictate/connection.d.ts +18 -0
- package/vendor/@stringsync/splates-server/dictate/dictate.d.ts +16 -0
- package/vendor/@stringsync/splates-server/dictate/index.d.ts +4 -0
- package/vendor/@stringsync/splates-server/dictate/personal.d.ts +26 -0
- package/vendor/@stringsync/splates-server/dictate/transcriber.d.ts +16 -0
- package/vendor/@stringsync/splates-server/dictate/vocabulary.d.ts +12 -0
- package/vendor/@stringsync/splates-server/evals/agents-routes.d.ts +27 -0
- package/vendor/@stringsync/splates-server/evals/agents.d.ts +25 -0
- package/vendor/@stringsync/splates-server/evals/contract.d.ts +73 -0
- package/vendor/@stringsync/splates-server/evals/done.d.ts +11 -0
- package/vendor/@stringsync/splates-server/evals/import.d.ts +10 -0
- package/vendor/@stringsync/splates-server/evals/index.d.ts +19 -0
- package/vendor/@stringsync/splates-server/evals/index.js +40 -0
- package/vendor/@stringsync/splates-server/evals/inspect.d.ts +66 -0
- package/vendor/@stringsync/splates-server/evals/launch-routes.d.ts +39 -0
- package/vendor/@stringsync/splates-server/evals/launch.d.ts +123 -0
- package/vendor/@stringsync/splates-server/evals/routes.d.ts +39 -0
- package/vendor/@stringsync/splates-server/evals/store.d.ts +17 -0
- package/vendor/@stringsync/splates-server/evals/target.d.ts +3 -0
- package/vendor/@stringsync/splates-server/evals/types.d.ts +105 -0
- package/vendor/@stringsync/splates-server/exit.d.ts +55 -0
- package/vendor/@stringsync/splates-server/exit.js +12 -0
- package/vendor/@stringsync/splates-server/git-identity.d.ts +17 -0
- package/vendor/@stringsync/splates-server/git-process.d.ts +8 -0
- package/vendor/@stringsync/splates-server/git.d.ts +168 -0
- package/vendor/@stringsync/splates-server/hooks/commands.d.ts +31 -0
- package/vendor/@stringsync/splates-server/hooks/edit.d.ts +24 -0
- package/vendor/@stringsync/splates-server/hooks/events.d.ts +20 -0
- package/vendor/@stringsync/splates-server/hooks/groomer.d.ts +8 -0
- package/vendor/@stringsync/splates-server/hooks/index.d.ts +17 -0
- package/vendor/@stringsync/splates-server/hooks/index.js +61 -0
- package/vendor/@stringsync/splates-server/hooks/now.d.ts +9 -0
- package/vendor/@stringsync/splates-server/hooks/routes.d.ts +39 -0
- package/vendor/@stringsync/splates-server/hooks/runner.d.ts +75 -0
- package/vendor/@stringsync/splates-server/hooks/runs.d.ts +38 -0
- package/vendor/@stringsync/splates-server/hooks/schedule.d.ts +10 -0
- package/vendor/@stringsync/splates-server/hooks/scheduler.d.ts +28 -0
- package/vendor/@stringsync/splates-server/hooks/store.d.ts +110 -0
- package/vendor/@stringsync/splates-server/index-01z7ycdk.js +6 -0
- package/vendor/@stringsync/splates-server/index-0jttnv86.js +1309 -0
- package/vendor/@stringsync/splates-server/index-5axhdy8c.js +692 -0
- package/vendor/@stringsync/splates-server/index-76t8y8h5.js +779 -0
- package/vendor/@stringsync/splates-server/index-7s01973c.js +2356 -0
- package/vendor/@stringsync/splates-server/index-acbcm66f.js +1468 -0
- package/vendor/@stringsync/splates-server/index-caep3sde.js +27140 -0
- package/vendor/@stringsync/splates-server/index-e9z7s5hh.js +641 -0
- package/vendor/@stringsync/splates-server/index-g18nxyn7.js +99 -0
- package/vendor/@stringsync/splates-server/index-kmzdvvt0.js +23 -0
- package/vendor/@stringsync/splates-server/index-raqrwzdq.js +952 -0
- package/vendor/@stringsync/splates-server/index-t9w5a8ed.js +60 -0
- package/vendor/@stringsync/splates-server/limited.d.ts +8 -0
- package/vendor/@stringsync/splates-server/log.d.ts +14 -0
- package/vendor/@stringsync/splates-server/log.js +32 -0
- package/vendor/@stringsync/splates-server/merge/attribution.d.ts +24 -0
- package/vendor/@stringsync/splates-server/merge/batch.d.ts +119 -0
- package/vendor/@stringsync/splates-server/merge/blame.d.ts +21 -0
- package/vendor/@stringsync/splates-server/merge/branches.d.ts +151 -0
- package/vendor/@stringsync/splates-server/merge/charge.d.ts +18 -0
- package/vendor/@stringsync/splates-server/merge/clear-gate.d.ts +7 -0
- package/vendor/@stringsync/splates-server/merge/cores.d.ts +60 -0
- package/vendor/@stringsync/splates-server/merge/estimates.d.ts +28 -0
- package/vendor/@stringsync/splates-server/merge/finish.d.ts +43 -0
- package/vendor/@stringsync/splates-server/merge/follow.d.ts +50 -0
- package/vendor/@stringsync/splates-server/merge/gate.d.ts +108 -0
- package/vendor/@stringsync/splates-server/merge/github-app.d.ts +99 -0
- package/vendor/@stringsync/splates-server/merge/github-refused.d.ts +5 -0
- package/vendor/@stringsync/splates-server/merge/groups.d.ts +8 -0
- package/vendor/@stringsync/splates-server/merge/index.d.ts +19 -0
- package/vendor/@stringsync/splates-server/merge/index.js +46 -0
- package/vendor/@stringsync/splates-server/merge/landed.d.ts +28 -0
- package/vendor/@stringsync/splates-server/merge/landing.d.ts +38 -0
- package/vendor/@stringsync/splates-server/merge/local-landing.d.ts +11 -0
- package/vendor/@stringsync/splates-server/merge/merge-state.d.ts +37 -0
- package/vendor/@stringsync/splates-server/merge/merge.d.ts +45 -0
- package/vendor/@stringsync/splates-server/merge/output.d.ts +19 -0
- package/vendor/@stringsync/splates-server/merge/phases.d.ts +27 -0
- package/vendor/@stringsync/splates-server/merge/pre-lock.d.ts +28 -0
- package/vendor/@stringsync/splates-server/merge/preflight.d.ts +16 -0
- package/vendor/@stringsync/splates-server/merge/queue-failures.d.ts +11 -0
- package/vendor/@stringsync/splates-server/merge/rebase.d.ts +34 -0
- package/vendor/@stringsync/splates-server/merge/recent-failures.d.ts +10 -0
- package/vendor/@stringsync/splates-server/merge/refusal.d.ts +58 -0
- package/vendor/@stringsync/splates-server/merge/split.d.ts +34 -0
- package/vendor/@stringsync/splates-server/merge/steps.d.ts +37 -0
- package/vendor/@stringsync/splates-server/merge/test-report.d.ts +29 -0
- package/vendor/@stringsync/splates-server/merge/timing.d.ts +20 -0
- package/vendor/@stringsync/splates-server/merge/trunk.d.ts +69 -0
- package/vendor/@stringsync/splates-server/models/codex-limits.d.ts +19 -0
- package/vendor/@stringsync/splates-server/models/effort.d.ts +22 -0
- package/vendor/@stringsync/splates-server/models/index.d.ts +13 -0
- package/vendor/@stringsync/splates-server/models/index.js +76 -0
- package/vendor/@stringsync/splates-server/models/kimi-limits.d.ts +37 -0
- package/vendor/@stringsync/splates-server/models/kimi-usage.d.ts +19 -0
- package/vendor/@stringsync/splates-server/models/kimi.d.ts +10 -0
- package/vendor/@stringsync/splates-server/models/limits.d.ts +32 -0
- package/vendor/@stringsync/splates-server/models/models.d.ts +36 -0
- package/vendor/@stringsync/splates-server/models/offered.d.ts +47 -0
- package/vendor/@stringsync/splates-server/models/opencode-usage.d.ts +37 -0
- package/vendor/@stringsync/splates-server/models/roster.d.ts +130 -0
- package/vendor/@stringsync/splates-server/plans/asked.d.ts +99 -0
- package/vendor/@stringsync/splates-server/plans/browser.d.ts +13 -0
- package/vendor/@stringsync/splates-server/plans/decided.d.ts +12 -0
- package/vendor/@stringsync/splates-server/plans/demo.d.ts +29 -0
- package/vendor/@stringsync/splates-server/plans/index.d.ts +16 -0
- package/vendor/@stringsync/splates-server/plans/index.js +137 -0
- package/vendor/@stringsync/splates-server/plans/needs.d.ts +131 -0
- package/vendor/@stringsync/splates-server/plans/permission.d.ts +64 -0
- package/vendor/@stringsync/splates-server/plans/plan.d.ts +223 -0
- package/vendor/@stringsync/splates-server/plans/prompts.d.ts +148 -0
- package/vendor/@stringsync/splates-server/plans/reply.d.ts +45 -0
- package/vendor/@stringsync/splates-server/plans/run-command.d.ts +21 -0
- package/vendor/@stringsync/splates-server/plans/store.d.ts +26 -0
- package/vendor/@stringsync/splates-server/plans/unanswered.d.ts +15 -0
- package/vendor/@stringsync/splates-server/ports/index.d.ts +8 -0
- package/vendor/@stringsync/splates-server/ports/index.js +36 -0
- package/vendor/@stringsync/splates-server/ports/list.d.ts +22 -0
- package/vendor/@stringsync/splates-server/ports/routes.d.ts +64 -0
- package/vendor/@stringsync/splates-server/ports/slot-tunnel.d.ts +24 -0
- package/vendor/@stringsync/splates-server/ports/slot.d.ts +28 -0
- package/vendor/@stringsync/splates-server/ports/slots.d.ts +150 -0
- package/vendor/@stringsync/splates-server/ports/socket.d.ts +26 -0
- package/vendor/@stringsync/splates-server/ports/task-ports.d.ts +39 -0
- package/vendor/@stringsync/splates-server/prices/index.d.ts +2 -0
- package/vendor/@stringsync/splates-server/prices/prices.d.ts +65 -0
- package/vendor/@stringsync/splates-server/projects/everywhere-routes.d.ts +110 -0
- package/vendor/@stringsync/splates-server/projects/everywhere.d.ts +43 -0
- package/vendor/@stringsync/splates-server/projects/general.d.ts +4 -0
- package/vendor/@stringsync/splates-server/projects/index.d.ts +10 -0
- package/vendor/@stringsync/splates-server/projects/index.js +36 -0
- package/vendor/@stringsync/splates-server/projects/init.d.ts +28 -0
- package/vendor/@stringsync/splates-server/projects/picker.d.ts +64 -0
- package/vendor/@stringsync/splates-server/projects/projects.d.ts +155 -0
- package/vendor/@stringsync/splates-server/projects/reaches.d.ts +26 -0
- package/vendor/@stringsync/splates-server/push/index.d.ts +2 -0
- package/vendor/@stringsync/splates-server/push/notices.d.ts +44 -0
- package/vendor/@stringsync/splates-server/push/push.d.ts +91 -0
- package/vendor/@stringsync/splates-server/queue/commands.d.ts +44 -0
- package/vendor/@stringsync/splates-server/queue/index.d.ts +7 -0
- package/vendor/@stringsync/splates-server/queue/index.js +44 -0
- package/vendor/@stringsync/splates-server/queue/moves.d.ts +15 -0
- package/vendor/@stringsync/splates-server/queue/name.d.ts +9 -0
- package/vendor/@stringsync/splates-server/queue/order.d.ts +50 -0
- package/vendor/@stringsync/splates-server/queue/runner.d.ts +129 -0
- package/vendor/@stringsync/splates-server/records/elsewhere.d.ts +27 -0
- package/vendor/@stringsync/splates-server/records/events.d.ts +556 -0
- package/vendor/@stringsync/splates-server/records/format.d.ts +92 -0
- package/vendor/@stringsync/splates-server/records/home.d.ts +72 -0
- package/vendor/@stringsync/splates-server/records/index.d.ts +10 -0
- package/vendor/@stringsync/splates-server/records/index.js +40 -0
- package/vendor/@stringsync/splates-server/records/journal.d.ts +65 -0
- package/vendor/@stringsync/splates-server/records/lease-lock.d.ts +29 -0
- package/vendor/@stringsync/splates-server/records/migration.d.ts +94 -0
- package/vendor/@stringsync/splates-server/records/one-task-store.d.ts +15 -0
- package/vendor/@stringsync/splates-server/records/repository.d.ts +137 -0
- package/vendor/@stringsync/splates-server/records/task-files.d.ts +8 -0
- package/vendor/@stringsync/splates-server/records/task-stages.d.ts +7 -0
- package/vendor/@stringsync/splates-server/records/to-sqlite.d.ts +3 -0
- package/vendor/@stringsync/splates-server/replica/aws-sign.d.ts +30 -0
- package/vendor/@stringsync/splates-server/replica/dir.d.ts +17 -0
- package/vendor/@stringsync/splates-server/replica/index.d.ts +14 -0
- package/vendor/@stringsync/splates-server/replica/index.js +29 -0
- package/vendor/@stringsync/splates-server/replica/layout.d.ts +45 -0
- package/vendor/@stringsync/splates-server/replica/place.d.ts +31 -0
- package/vendor/@stringsync/splates-server/replica/replica.d.ts +37 -0
- package/vendor/@stringsync/splates-server/replica/replicator.d.ts +102 -0
- package/vendor/@stringsync/splates-server/replica/restore.d.ts +40 -0
- package/vendor/@stringsync/splates-server/replica/s3.d.ts +45 -0
- package/vendor/@stringsync/splates-server/replica/shipped.d.ts +2 -0
- package/vendor/@stringsync/splates-server/replica/status.d.ts +18 -0
- package/vendor/@stringsync/splates-server/server/assets.d.ts +35 -0
- package/vendor/@stringsync/splates-server/server/automations.d.ts +26 -0
- package/vendor/@stringsync/splates-server/server/chunk-files.d.ts +4 -0
- package/vendor/@stringsync/splates-server/server/conflict-watch.d.ts +22 -0
- package/vendor/@stringsync/splates-server/server/early-warning.d.ts +7 -0
- package/vendor/@stringsync/splates-server/server/general.d.ts +53 -0
- package/vendor/@stringsync/splates-server/server/groomer.d.ts +53 -0
- package/vendor/@stringsync/splates-server/server/held.d.ts +10 -0
- package/vendor/@stringsync/splates-server/server/http.d.ts +76 -0
- package/vendor/@stringsync/splates-server/server/index.d.ts +16 -0
- package/vendor/@stringsync/splates-server/server/index.js +14342 -0
- package/vendor/@stringsync/splates-server/server/interrupt.d.ts +24 -0
- package/vendor/@stringsync/splates-server/server/loop-watch.d.ts +12 -0
- package/vendor/@stringsync/splates-server/server/migrations.d.ts +46 -0
- package/vendor/@stringsync/splates-server/server/options.d.ts +143 -0
- package/vendor/@stringsync/splates-server/server/pages.d.ts +35 -0
- package/vendor/@stringsync/splates-server/server/ports.d.ts +11 -0
- package/vendor/@stringsync/splates-server/server/premerge.d.ts +61 -0
- package/vendor/@stringsync/splates-server/server/project-watch.d.ts +94 -0
- package/vendor/@stringsync/splates-server/server/project.d.ts +239 -0
- package/vendor/@stringsync/splates-server/server/pulse.d.ts +8 -0
- package/vendor/@stringsync/splates-server/server/release.d.ts +41 -0
- package/vendor/@stringsync/splates-server/server/replicas.d.ts +23 -0
- package/vendor/@stringsync/splates-server/server/restart.d.ts +177 -0
- package/vendor/@stringsync/splates-server/server/runtime-deps.d.ts +19 -0
- package/vendor/@stringsync/splates-server/server/server.d.ts +19 -0
- package/vendor/@stringsync/splates-server/server/servers.d.ts +31 -0
- package/vendor/@stringsync/splates-server/server/serving.d.ts +28 -0
- package/vendor/@stringsync/splates-server/server/shared.d.ts +14 -0
- package/vendor/@stringsync/splates-server/server/skills.d.ts +16 -0
- package/vendor/@stringsync/splates-server/server/sockets.d.ts +13 -0
- package/vendor/@stringsync/splates-server/server/start-settings.d.ts +15 -0
- package/vendor/@stringsync/splates-server/server/start.d.ts +21 -0
- package/vendor/@stringsync/splates-server/server/suite-grant.d.ts +26 -0
- package/vendor/@stringsync/splates-server/server/supervise.d.ts +81 -0
- package/vendor/@stringsync/splates-server/server/ticketed-lock.d.ts +80 -0
- package/vendor/@stringsync/splates-server/server/update-records.d.ts +8 -0
- package/vendor/@stringsync/splates-server/server/update.d.ts +56 -0
- package/vendor/@stringsync/splates-server/server/versions.d.ts +53 -0
- package/vendor/@stringsync/splates-server/setup/area-auto-pick.d.ts +7 -0
- package/vendor/@stringsync/splates-server/setup/area-dictation.d.ts +3 -0
- package/vendor/@stringsync/splates-server/setup/area-droplet.d.ts +3 -0
- package/vendor/@stringsync/splates-server/setup/area-evals.d.ts +3 -0
- package/vendor/@stringsync/splates-server/setup/area-github.d.ts +8 -0
- package/vendor/@stringsync/splates-server/setup/area-native.d.ts +7 -0
- package/vendor/@stringsync/splates-server/setup/area-opencode.d.ts +5 -0
- package/vendor/@stringsync/splates-server/setup/area-remote.d.ts +3 -0
- package/vendor/@stringsync/splates-server/setup/area-replica.d.ts +3 -0
- package/vendor/@stringsync/splates-server/setup/area-workers.d.ts +5 -0
- package/vendor/@stringsync/splates-server/setup/areas.d.ts +7 -0
- package/vendor/@stringsync/splates-server/setup/checks.d.ts +8 -0
- package/vendor/@stringsync/splates-server/setup/fields.d.ts +69 -0
- package/vendor/@stringsync/splates-server/setup/index.d.ts +8 -0
- package/vendor/@stringsync/splates-server/setup/index.js +25 -0
- package/vendor/@stringsync/splates-server/setup/opencode-model-error.d.ts +3 -0
- package/vendor/@stringsync/splates-server/setup/opencode-models.d.ts +44 -0
- package/vendor/@stringsync/splates-server/setup/opencode-recipe.d.ts +33 -0
- package/vendor/@stringsync/splates-server/setup/opencode-routes.d.ts +17 -0
- package/vendor/@stringsync/splates-server/setup/opencode.d.ts +61 -0
- package/vendor/@stringsync/splates-server/setup/project.d.ts +10 -0
- package/vendor/@stringsync/splates-server/setup/routes.d.ts +31 -0
- package/vendor/@stringsync/splates-server/setup/setup.d.ts +235 -0
- package/vendor/@stringsync/splates-server/setup/step-problem.d.ts +3 -0
- package/vendor/@stringsync/splates-server/setup/undo.d.ts +80 -0
- package/vendor/@stringsync/splates-server/ship/approval-watch.d.ts +57 -0
- package/vendor/@stringsync/splates-server/ship/approval.d.ts +17 -0
- package/vendor/@stringsync/splates-server/ship/cascade-routes.d.ts +25 -0
- package/vendor/@stringsync/splates-server/ship/cascade.d.ts +70 -0
- package/vendor/@stringsync/splates-server/ship/commands.d.ts +26 -0
- package/vendor/@stringsync/splates-server/ship/git.d.ts +31 -0
- package/vendor/@stringsync/splates-server/ship/graph.d.ts +60 -0
- package/vendor/@stringsync/splates-server/ship/history.d.ts +51 -0
- package/vendor/@stringsync/splates-server/ship/index.d.ts +28 -0
- package/vendor/@stringsync/splates-server/ship/live.d.ts +40 -0
- package/vendor/@stringsync/splates-server/ship/mechanical.d.ts +30 -0
- package/vendor/@stringsync/splates-server/ship/npm-terminal.d.ts +14 -0
- package/vendor/@stringsync/splates-server/ship/plan.d.ts +90 -0
- package/vendor/@stringsync/splates-server/ship/progress.d.ts +3 -0
- package/vendor/@stringsync/splates-server/ship/published-notice.d.ts +29 -0
- package/vendor/@stringsync/splates-server/ship/record.d.ts +55 -0
- package/vendor/@stringsync/splates-server/ship/registry.d.ts +13 -0
- package/vendor/@stringsync/splates-server/ship/release-events.d.ts +47 -0
- package/vendor/@stringsync/splates-server/ship/release-steps.d.ts +66 -0
- package/vendor/@stringsync/splates-server/ship/routes.d.ts +14 -0
- package/vendor/@stringsync/splates-server/ship/run.d.ts +132 -0
- package/vendor/@stringsync/splates-server/ship/selection.d.ts +36 -0
- package/vendor/@stringsync/splates-server/ship/served.d.ts +4 -0
- package/vendor/@stringsync/splates-server/ship/stages.d.ts +69 -0
- package/vendor/@stringsync/splates-server/ship/steps.d.ts +69 -0
- package/vendor/@stringsync/splates-server/ship/token-request.d.ts +11 -0
- package/vendor/@stringsync/splates-server/ship/token.d.ts +21 -0
- package/vendor/@stringsync/splates-server/spend/adapters.d.ts +5 -0
- package/vendor/@stringsync/splates-server/spend/billing.d.ts +38 -0
- package/vendor/@stringsync/splates-server/spend/index.d.ts +15 -0
- package/vendor/@stringsync/splates-server/spend/plans.d.ts +45 -0
- package/vendor/@stringsync/splates-server/spend/providers.d.ts +45 -0
- package/vendor/@stringsync/splates-server/spend/rates.d.ts +23 -0
- package/vendor/@stringsync/splates-server/spend/report.d.ts +39 -0
- package/vendor/@stringsync/splates-server/spend/routes.d.ts +46 -0
- package/vendor/@stringsync/splates-server/spend/spend.d.ts +15 -0
- package/vendor/@stringsync/splates-server/spend/totals.d.ts +63 -0
- package/vendor/@stringsync/splates-server/spend/turn.d.ts +39 -0
- package/vendor/@stringsync/splates-server/stats/adherence.d.ts +40 -0
- package/vendor/@stringsync/splates-server/stats/baselines.d.ts +55 -0
- package/vendor/@stringsync/splates-server/stats/budget-routes.d.ts +21 -0
- package/vendor/@stringsync/splates-server/stats/fact-tasks.d.ts +19 -0
- package/vendor/@stringsync/splates-server/stats/finding-facts.d.ts +37 -0
- package/vendor/@stringsync/splates-server/stats/findings.d.ts +89 -0
- package/vendor/@stringsync/splates-server/stats/index.d.ts +12 -0
- package/vendor/@stringsync/splates-server/stats/index.js +30 -0
- package/vendor/@stringsync/splates-server/stats/landed.d.ts +14 -0
- package/vendor/@stringsync/splates-server/stats/outcomes.d.ts +207 -0
- package/vendor/@stringsync/splates-server/stats/overrides.d.ts +19 -0
- package/vendor/@stringsync/splates-server/stats/routes.d.ts +23 -0
- package/vendor/@stringsync/splates-server/stats/scry-models.d.ts +22 -0
- package/vendor/@stringsync/splates-server/stats/skill-checks.d.ts +59 -0
- package/vendor/@stringsync/splates-server/stats/stats.d.ts +176 -0
- package/vendor/@stringsync/splates-server/stats/task-log.d.ts +67 -0
- package/vendor/@stringsync/splates-server/storage/atomic.d.ts +13 -0
- package/vendor/@stringsync/splates-server/storage/collection.d.ts +30 -0
- package/vendor/@stringsync/splates-server/storage/document.d.ts +26 -0
- package/vendor/@stringsync/splates-server/storage/fs-collection.d.ts +26 -0
- package/vendor/@stringsync/splates-server/storage/fs-document.d.ts +16 -0
- package/vendor/@stringsync/splates-server/storage/fs-log.d.ts +31 -0
- package/vendor/@stringsync/splates-server/storage/fs.d.ts +48 -0
- package/vendor/@stringsync/splates-server/storage/index.d.ts +11 -0
- package/vendor/@stringsync/splates-server/storage/index.js +18 -0
- package/vendor/@stringsync/splates-server/storage/json.d.ts +10 -0
- package/vendor/@stringsync/splates-server/storage/key.d.ts +7 -0
- package/vendor/@stringsync/splates-server/storage/log.d.ts +60 -0
- package/vendor/@stringsync/splates-server/storage/schema.d.ts +7 -0
- package/vendor/@stringsync/splates-server/storage/sqlite-collection.d.ts +31 -0
- package/vendor/@stringsync/splates-server/storage/sqlite-db.d.ts +62 -0
- package/vendor/@stringsync/splates-server/storage/sqlite-document.d.ts +20 -0
- package/vendor/@stringsync/splates-server/storage/sqlite-import.d.ts +11 -0
- package/vendor/@stringsync/splates-server/storage/sqlite-keys.d.ts +17 -0
- package/vendor/@stringsync/splates-server/storage/sqlite-lock.d.ts +25 -0
- package/vendor/@stringsync/splates-server/storage/sqlite-log.d.ts +31 -0
- package/vendor/@stringsync/splates-server/storage/sqlite.d.ts +53 -0
- package/vendor/@stringsync/splates-server/storage/storage.d.ts +87 -0
- package/vendor/@stringsync/splates-server/table.d.ts +5 -0
- package/vendor/@stringsync/splates-server/tasks/add.d.ts +45 -0
- package/vendor/@stringsync/splates-server/tasks/browser.d.ts +5 -0
- package/vendor/@stringsync/splates-server/tasks/checkpoint.d.ts +39 -0
- package/vendor/@stringsync/splates-server/tasks/claim.d.ts +14 -0
- package/vendor/@stringsync/splates-server/tasks/conflicts.d.ts +19 -0
- package/vendor/@stringsync/splates-server/tasks/diff.d.ts +29 -0
- package/vendor/@stringsync/splates-server/tasks/dispatched.d.ts +15 -0
- package/vendor/@stringsync/splates-server/tasks/editors.d.ts +22 -0
- package/vendor/@stringsync/splates-server/tasks/finished.d.ts +81 -0
- package/vendor/@stringsync/splates-server/tasks/follow.d.ts +48 -0
- package/vendor/@stringsync/splates-server/tasks/index.d.ts +30 -0
- package/vendor/@stringsync/splates-server/tasks/index.js +90 -0
- package/vendor/@stringsync/splates-server/tasks/landings.d.ts +17 -0
- package/vendor/@stringsync/splates-server/tasks/list.d.ts +18 -0
- package/vendor/@stringsync/splates-server/tasks/merge-output.d.ts +13 -0
- package/vendor/@stringsync/splates-server/tasks/open.d.ts +15 -0
- package/vendor/@stringsync/splates-server/tasks/overlaps.d.ts +16 -0
- package/vendor/@stringsync/splates-server/tasks/path.d.ts +13 -0
- package/vendor/@stringsync/splates-server/tasks/recommend.d.ts +30 -0
- package/vendor/@stringsync/splates-server/tasks/remove.d.ts +47 -0
- package/vendor/@stringsync/splates-server/tasks/retry.d.ts +35 -0
- package/vendor/@stringsync/splates-server/tasks/routes.d.ts +23 -0
- package/vendor/@stringsync/splates-server/tasks/show.d.ts +137 -0
- package/vendor/@stringsync/splates-server/tasks/snapshot.d.ts +86 -0
- package/vendor/@stringsync/splates-server/tasks/started-records.d.ts +71 -0
- package/vendor/@stringsync/splates-server/tasks/wait.d.ts +47 -0
- package/vendor/@stringsync/splates-server/tasks/worktree-checkouts.d.ts +10 -0
- package/vendor/@stringsync/splates-server/tasks/worktree-service.d.ts +151 -0
- package/vendor/@stringsync/splates-server/tasks/worktree.d.ts +342 -0
- package/vendor/@stringsync/splates-server/terminal/connection.d.ts +19 -0
- package/vendor/@stringsync/splates-server/terminal/held.d.ts +22 -0
- package/vendor/@stringsync/splates-server/terminal/index.d.ts +7 -0
- package/vendor/@stringsync/splates-server/terminal/pty.d.ts +45 -0
- package/vendor/@stringsync/splates-server/terminal/remote-pty.d.ts +34 -0
- package/vendor/@stringsync/splates-server/terminal/shell.d.ts +70 -0
- package/vendor/@stringsync/splates-server/terminal/spawn.d.ts +22 -0
- package/vendor/@stringsync/splates-server/terminal/terminal.d.ts +52 -0
- package/vendor/@stringsync/splates-server/tunnel/access.d.ts +61 -0
- package/vendor/@stringsync/splates-server/tunnel/cloudflare-api.d.ts +25 -0
- package/vendor/@stringsync/splates-server/tunnel/cloudflare-error.d.ts +5 -0
- package/vendor/@stringsync/splates-server/tunnel/cloudflared.d.ts +43 -0
- package/vendor/@stringsync/splates-server/tunnel/index.d.ts +14 -0
- package/vendor/@stringsync/splates-server/tunnel/index.js +70 -0
- package/vendor/@stringsync/splates-server/tunnel/machine.d.ts +18 -0
- package/vendor/@stringsync/splates-server/tunnel/provider.d.ts +37 -0
- package/vendor/@stringsync/splates-server/tunnel/remove.d.ts +35 -0
- package/vendor/@stringsync/splates-server/tunnel/saved-ports-host.d.ts +26 -0
- package/vendor/@stringsync/splates-server/tunnel/saved.d.ts +63 -0
- package/vendor/@stringsync/splates-server/tunnel/setup.d.ts +123 -0
- package/vendor/@stringsync/splates-server/tunnel/tunnel.d.ts +38 -0
- package/vendor/@stringsync/splates-server/workers/admin.d.ts +37 -0
- package/vendor/@stringsync/splates-server/workers/call-host.d.ts +68 -0
- package/vendor/@stringsync/splates-server/workers/channel.d.ts +90 -0
- package/vendor/@stringsync/splates-server/workers/connection.d.ts +24 -0
- package/vendor/@stringsync/splates-server/workers/coordinator-state.d.ts +44 -0
- package/vendor/@stringsync/splates-server/workers/daemon.d.ts +128 -0
- package/vendor/@stringsync/splates-server/workers/darwin-footprint.d.ts +7 -0
- package/vendor/@stringsync/splates-server/workers/darwin-temperature.d.ts +7 -0
- package/vendor/@stringsync/splates-server/workers/frame-too-large.d.ts +5 -0
- package/vendor/@stringsync/splates-server/workers/git.d.ts +11 -0
- package/vendor/@stringsync/splates-server/workers/gone.d.ts +36 -0
- package/vendor/@stringsync/splates-server/workers/identity.d.ts +30 -0
- package/vendor/@stringsync/splates-server/workers/index.d.ts +40 -0
- package/vendor/@stringsync/splates-server/workers/index.js +90 -0
- package/vendor/@stringsync/splates-server/workers/lifecycle.d.ts +14 -0
- package/vendor/@stringsync/splates-server/workers/list.d.ts +93 -0
- package/vendor/@stringsync/splates-server/workers/load.d.ts +55 -0
- package/vendor/@stringsync/splates-server/workers/local-id.d.ts +11 -0
- package/vendor/@stringsync/splates-server/workers/local-update.d.ts +81 -0
- package/vendor/@stringsync/splates-server/workers/log-file.d.ts +24 -0
- package/vendor/@stringsync/splates-server/workers/machine.d.ts +47 -0
- package/vendor/@stringsync/splates-server/workers/orphan.d.ts +31 -0
- package/vendor/@stringsync/splates-server/workers/os-sensors.d.ts +49 -0
- package/vendor/@stringsync/splates-server/workers/placement.d.ts +39 -0
- package/vendor/@stringsync/splates-server/workers/process-host.d.ts +60 -0
- package/vendor/@stringsync/splates-server/workers/process.d.ts +33 -0
- package/vendor/@stringsync/splates-server/workers/protocol.d.ts +153 -0
- package/vendor/@stringsync/splates-server/workers/pty-host.d.ts +35 -0
- package/vendor/@stringsync/splates-server/workers/queue.d.ts +39 -0
- package/vendor/@stringsync/splates-server/workers/records.d.ts +43 -0
- package/vendor/@stringsync/splates-server/workers/registry.d.ts +101 -0
- package/vendor/@stringsync/splates-server/workers/replay.d.ts +25 -0
- package/vendor/@stringsync/splates-server/workers/routes.d.ts +119 -0
- package/vendor/@stringsync/splates-server/workers/run-options.d.ts +11 -0
- package/vendor/@stringsync/splates-server/workers/run.d.ts +10 -0
- package/vendor/@stringsync/splates-server/workers/scheduler.d.ts +171 -0
- package/vendor/@stringsync/splates-server/workers/server-of.d.ts +23 -0
- package/vendor/@stringsync/splates-server/workers/server-socket.d.ts +25 -0
- package/vendor/@stringsync/splates-server/workers/session.d.ts +240 -0
- package/vendor/@stringsync/splates-server/workers/socket.d.ts +21 -0
- package/vendor/@stringsync/splates-server/workers/unix-listener.d.ts +23 -0
- package/vendor/@stringsync/splates-server/workers/unix-socket.d.ts +30 -0
- package/vendor/@stringsync/splates-server/workers/websocket-socket.d.ts +24 -0
- package/vendor/@stringsync/splates-server/workers/worker.d.ts +98 -0
- package/vendor/core/LICENSE +21 -0
- package/vendor/core/abort/aborts.d.ts +10 -0
- package/vendor/core/abort/index.d.ts +1 -0
- package/vendor/core/abort/index.js +24 -0
- package/vendor/core/assert/assert-error.d.ts +4 -0
- package/vendor/core/assert/assert.d.ts +24 -0
- package/vendor/core/assert/ensure.d.ts +18 -0
- package/vendor/core/assert/index.d.ts +3 -0
- package/vendor/core/assert/index.js +75 -0
- package/vendor/core/cmd/cli.d.ts +70 -0
- package/vendor/core/cmd/command.d.ts +96 -0
- package/vendor/core/cmd/deps.d.ts +12 -0
- package/vendor/core/cmd/help.d.ts +16 -0
- package/vendor/core/cmd/index.d.ts +6 -0
- package/vendor/core/cmd/index.js +477 -0
- package/vendor/core/cmd/middleware.d.ts +15 -0
- package/vendor/core/cmd/timed.d.ts +15 -0
- package/vendor/core/creds/credential-proxy.d.ts +55 -0
- package/vendor/core/creds/credential-source.d.ts +19 -0
- package/vendor/core/creds/credentials.d.ts +28 -0
- package/vendor/core/creds/dotenv-file.d.ts +22 -0
- package/vendor/core/creds/environment.d.ts +18 -0
- package/vendor/core/creds/index.d.ts +8 -0
- package/vendor/core/creds/index.js +337 -0
- package/vendor/core/creds/memory-secret-store.d.ts +33 -0
- package/vendor/core/creds/secret-store.d.ts +14 -0
- package/vendor/core/creds/system-secret-store.d.ts +49 -0
- package/vendor/core/dictate/buffered-sink.d.ts +9 -0
- package/vendor/core/dictate/cue.d.ts +10 -0
- package/vendor/core/dictate/dictation-failure.d.ts +5 -0
- package/vendor/core/dictate/dictation-link.d.ts +18 -0
- package/vendor/core/dictate/dictation-message.d.ts +24 -0
- package/vendor/core/dictate/dictation-relay.d.ts +28 -0
- package/vendor/core/dictate/index.d.ts +10 -0
- package/vendor/core/dictate/index.js +132 -0
- package/vendor/core/dictate/microphone.d.ts +42 -0
- package/vendor/core/dictate/openai-transcriber.d.ts +22 -0
- package/vendor/core/dictate/openai-transcription.d.ts +27 -0
- package/vendor/core/dictate/pcm.d.ts +5 -0
- package/vendor/core/dictate/pcm16-encoder.d.ts +20 -0
- package/vendor/core/dictate/server.d.ts +1 -0
- package/vendor/core/dictate/server.js +153 -0
- package/vendor/core/dictate/transcriber.d.ts +23 -0
- package/vendor/core/disposable/async-disposer.d.ts +15 -0
- package/vendor/core/disposable/async-resource.d.ts +4 -0
- package/vendor/core/disposable/disposables.d.ts +8 -0
- package/vendor/core/disposable/disposer.d.ts +13 -0
- package/vendor/core/disposable/index.d.ts +5 -0
- package/vendor/core/disposable/index.js +96 -0
- package/vendor/core/disposable/resource.d.ts +4 -0
- package/vendor/core/events/dispatcher.d.ts +18 -0
- package/vendor/core/events/eventful.d.ts +7 -0
- package/vendor/core/events/events.d.ts +14 -0
- package/vendor/core/events/index.d.ts +4 -0
- package/vendor/core/events/index.js +75 -0
- package/vendor/core/events/noop-events.d.ts +6 -0
- package/vendor/core/id/counter-id-provider.d.ts +6 -0
- package/vendor/core/id/id-provider.d.ts +7 -0
- package/vendor/core/id/index.d.ts +3 -0
- package/vendor/core/id/index.js +17 -0
- package/vendor/core/id/uuid-provider.d.ts +11 -0
- package/vendor/core/index-qk5dj664.js +4 -0
- package/vendor/core/log/color.d.ts +22 -0
- package/vendor/core/log/composite-logger.d.ts +7 -0
- package/vendor/core/log/console-logger.d.ts +6 -0
- package/vendor/core/log/index.d.ts +8 -0
- package/vendor/core/log/index.js +154 -0
- package/vendor/core/log/level-prefix-logger.d.ts +12 -0
- package/vendor/core/log/logger.d.ts +12 -0
- package/vendor/core/log/mdc-logger.d.ts +14 -0
- package/vendor/core/log/memory-logger.d.ts +8 -0
- package/vendor/core/log/prefix-logger.d.ts +12 -0
- package/vendor/core/md/index.d.ts +2 -0
- package/vendor/core/md/index.js +182 -0
- package/vendor/core/md/markdown.d.ts +56 -0
- package/vendor/core/md/writer.d.ts +22 -0
- package/vendor/core/push/base64url.d.ts +2 -0
- package/vendor/core/push/encrypt.d.ts +12 -0
- package/vendor/core/push/index.d.ts +4 -0
- package/vendor/core/push/index.js +137 -0
- package/vendor/core/push/push-failure.d.ts +7 -0
- package/vendor/core/push/pusher.d.ts +24 -0
- package/vendor/core/push/vapid.d.ts +18 -0
- package/vendor/core/push/web-pusher.d.ts +20 -0
- package/vendor/core/ship/artifact/artifact.d.ts +52 -0
- package/vendor/core/ship/bundle/bun-bundle.d.ts +71 -0
- package/vendor/core/ship/bundle/bundle-artifact.d.ts +21 -0
- package/vendor/core/ship/bundle/bundle.d.ts +13 -0
- package/vendor/core/ship/bundle/published.d.ts +45 -0
- package/vendor/core/ship/bundle/reach.d.ts +43 -0
- package/vendor/core/ship/bundle/vendor-bundle.d.ts +47 -0
- package/vendor/core/ship/cut.d.ts +64 -0
- package/vendor/core/ship/dry-run.d.ts +63 -0
- package/vendor/core/ship/git/cli-git.d.ts +25 -0
- package/vendor/core/ship/git/git-artifact.d.ts +23 -0
- package/vendor/core/ship/git/git.d.ts +19 -0
- package/vendor/core/ship/github/cli-github.d.ts +31 -0
- package/vendor/core/ship/github/cli-workflows.d.ts +25 -0
- package/vendor/core/ship/github/github-artifact.d.ts +18 -0
- package/vendor/core/ship/github/github.d.ts +10 -0
- package/vendor/core/ship/github/login.d.ts +3 -0
- package/vendor/core/ship/github/workflows.d.ts +27 -0
- package/vendor/core/ship/index.d.ts +26 -0
- package/vendor/core/ship/index.js +3203 -0
- package/vendor/core/ship/mirror/agent-files.d.ts +6 -0
- package/vendor/core/ship/mirror/mirror-build.d.ts +63 -0
- package/vendor/core/ship/mirror/mirror-guard.d.ts +10 -0
- package/vendor/core/ship/mirror/mirror-options.d.ts +75 -0
- package/vendor/core/ship/mirror/mirror-step.d.ts +109 -0
- package/vendor/core/ship/mirror/mirror-tooling.d.ts +59 -0
- package/vendor/core/ship/mirror/source-manifest.d.ts +27 -0
- package/vendor/core/ship/order.d.ts +15 -0
- package/vendor/core/ship/publish-workflow.d.ts +32 -0
- package/vendor/core/ship/registry/github-actions.d.ts +76 -0
- package/vendor/core/ship/registry/npm-registry.d.ts +70 -0
- package/vendor/core/ship/registry/registry-artifact.d.ts +31 -0
- package/vendor/core/ship/registry/registry.d.ts +85 -0
- package/vendor/core/ship/release-file.d.ts +22 -0
- package/vendor/core/ship/release-options.d.ts +122 -0
- package/vendor/core/ship/release.d.ts +61 -0
- package/vendor/core/ship/releases.d.ts +119 -0
- package/vendor/core/ship/shipped.d.ts +54 -0
- package/vendor/core/ship/skill-artifact.d.ts +27 -0
- package/vendor/core/ship/step-events.d.ts +91 -0
- package/vendor/core/ship/step-runner.d.ts +16 -0
- package/vendor/core/ship/step.d.ts +49 -0
- package/vendor/core/ship/trust.d.ts +11 -0
- package/vendor/core/ship/version.d.ts +9 -0
- package/vendor/core/ship/workspace/manifest-workspace.d.ts +61 -0
- package/vendor/core/ship/workspace/workspace.d.ts +29 -0
- package/vendor/core/skills/index.d.ts +1 -0
- package/vendor/core/skills/index.js +77 -0
- package/vendor/core/skills/project-skills.d.ts +53 -0
- package/vendor/core/system/fs/fs.d.ts +58 -0
- package/vendor/core/system/fs/node-fs.d.ts +18 -0
- package/vendor/core/system/glob/glob.d.ts +11 -0
- package/vendor/core/system/glob/node-glob.d.ts +12 -0
- package/vendor/core/system/heavy/heavy-jobs.d.ts +84 -0
- package/vendor/core/system/host-mapper/file-host-mapper.d.ts +20 -0
- package/vendor/core/system/host-mapper/host-mapper.d.ts +11 -0
- package/vendor/core/system/host-mapper/noop-host-mapper.d.ts +4 -0
- package/vendor/core/system/index.d.ts +25 -0
- package/vendor/core/system/index.js +1385 -0
- package/vendor/core/system/ip-provider/darwin-ip-provider.d.ts +6 -0
- package/vendor/core/system/ip-provider/ip-provider.d.ts +8 -0
- package/vendor/core/system/ip-provider/linux-ip-provider.d.ts +6 -0
- package/vendor/core/system/ip-provider/platform-ip-provider.d.ts +6 -0
- package/vendor/core/system/ip-provider/sequential-ip-provider.d.ts +6 -0
- package/vendor/core/system/ip-provider/static-ip-provider.d.ts +8 -0
- package/vendor/core/system/ip-provider/win32-ip-provider.d.ts +6 -0
- package/vendor/core/system/lock/file-lock.d.ts +50 -0
- package/vendor/core/system/lock/lock.d.ts +11 -0
- package/vendor/core/system/lock/memory-lock.d.ts +13 -0
- package/vendor/core/system/port-provider/open-port-provider.d.ts +38 -0
- package/vendor/core/system/port-provider/port-provider.d.ts +14 -0
- package/vendor/core/system/process-like/process-like.d.ts +22 -0
- package/vendor/core/system/ps/file-process.d.ts +40 -0
- package/vendor/core/system/ps/listening.d.ts +20 -0
- package/vendor/core/system/ps/node-ps.d.ts +39 -0
- package/vendor/core/system/ps/ps.d.ts +161 -0
- package/vendor/core/system/ps/reap.d.ts +22 -0
- package/vendor/core/system/undumpable.d.ts +32 -0
- package/vendor/core/system/walk.d.ts +10 -0
- package/vendor/core/time/clock/clock.d.ts +5 -0
- package/vendor/core/time/clock/system-clock.d.ts +5 -0
- package/vendor/core/time/debouncer.d.ts +25 -0
- package/vendor/core/time/duration.d.ts +38 -0
- package/vendor/core/time/index.d.ts +13 -0
- package/vendor/core/time/index.js +271 -0
- package/vendor/core/time/sleep.d.ts +2 -0
- package/vendor/core/time/stopwatch.d.ts +34 -0
- package/vendor/core/time/throttler.d.ts +26 -0
- package/vendor/core/time/time-ago.d.ts +14 -0
- package/vendor/core/time/timeouts.d.ts +12 -0
- package/vendor/core/time/timer/system-timer.d.ts +7 -0
- package/vendor/core/time/timer/timer.d.ts +11 -0
- package/vendor/core/time/wall-clock/system-wall-clock.d.ts +4 -0
- package/vendor/core/time/wall-clock/wall-clock.d.ts +14 -0
- package/waiting.d.ts +2 -2
- package/worker.d.ts +2 -2
|
@@ -0,0 +1,477 @@
|
|
|
1
|
+
// cmd/cli.ts
|
|
2
|
+
import { ConsoleLogger, color as color3 } from "../log/index.js";
|
|
3
|
+
import { NodePs } from "../system/index.js";
|
|
4
|
+
|
|
5
|
+
// cmd/command.ts
|
|
6
|
+
import { color as color2 } from "../log/index.js";
|
|
7
|
+
|
|
8
|
+
// cmd/help.ts
|
|
9
|
+
import { color } from "../log/index.js";
|
|
10
|
+
var INDENT = " ";
|
|
11
|
+
var GAP = " ";
|
|
12
|
+
var MIN_BESIDE = 30;
|
|
13
|
+
var UNDER = " ";
|
|
14
|
+
function table(rows, style, width) {
|
|
15
|
+
const pad = Math.max(0, ...rows.map(([label]) => label.length));
|
|
16
|
+
const column = INDENT.length + pad + GAP.length;
|
|
17
|
+
const beside = width === undefined || width - column >= MIN_BESIDE;
|
|
18
|
+
const laid = rows.map(([label, text]) => {
|
|
19
|
+
if (!text) {
|
|
20
|
+
return [`${INDENT}${style(label)}`];
|
|
21
|
+
}
|
|
22
|
+
if (beside) {
|
|
23
|
+
const [first, ...rest] = wrap(text, width && width - column);
|
|
24
|
+
return [
|
|
25
|
+
`${INDENT}${style(label.padEnd(pad))}${GAP}${first}`,
|
|
26
|
+
...rest.map((line) => `${" ".repeat(column)}${line}`)
|
|
27
|
+
];
|
|
28
|
+
}
|
|
29
|
+
const indent = `${INDENT}${UNDER}`;
|
|
30
|
+
return [
|
|
31
|
+
`${INDENT}${style(label)}`,
|
|
32
|
+
...wrap(text, width && width - indent.length).map((line) => `${indent}${line}`)
|
|
33
|
+
];
|
|
34
|
+
});
|
|
35
|
+
const parted = laid.some((lines) => lines.length > 1);
|
|
36
|
+
return laid.flatMap((lines, i) => parted && i > 0 ? ["", ...lines] : lines);
|
|
37
|
+
}
|
|
38
|
+
function wrap(text, width) {
|
|
39
|
+
if (width === undefined) {
|
|
40
|
+
return text.split(`
|
|
41
|
+
`);
|
|
42
|
+
}
|
|
43
|
+
const lines = [];
|
|
44
|
+
for (const paragraph of text.split(`
|
|
45
|
+
`)) {
|
|
46
|
+
let line = [];
|
|
47
|
+
let length = 0;
|
|
48
|
+
for (const word of paragraph.split(" ")) {
|
|
49
|
+
const size = color.strip(word).length;
|
|
50
|
+
if (line.length > 0 && length + 1 + size > width) {
|
|
51
|
+
lines.push(line.join(" "));
|
|
52
|
+
line = [];
|
|
53
|
+
length = 0;
|
|
54
|
+
}
|
|
55
|
+
length += (line.length > 0 ? 1 : 0) + size;
|
|
56
|
+
line.push(word);
|
|
57
|
+
}
|
|
58
|
+
lines.push(line.join(" "));
|
|
59
|
+
}
|
|
60
|
+
return lines;
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
// cmd/middleware.ts
|
|
64
|
+
function compose(middleware, action) {
|
|
65
|
+
return middleware.reduceRight((next, mw) => (ctx) => mw(ctx, next), action);
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
// cmd/command.ts
|
|
69
|
+
class Command {
|
|
70
|
+
name;
|
|
71
|
+
_description = "";
|
|
72
|
+
options = [];
|
|
73
|
+
args = [];
|
|
74
|
+
variadic;
|
|
75
|
+
middleware = [];
|
|
76
|
+
_action = () => {};
|
|
77
|
+
hasAction = false;
|
|
78
|
+
unknownOptions = false;
|
|
79
|
+
excessArguments = false;
|
|
80
|
+
passThrough = false;
|
|
81
|
+
constructor(name) {
|
|
82
|
+
this.name = name;
|
|
83
|
+
}
|
|
84
|
+
description(description) {
|
|
85
|
+
this._description = description;
|
|
86
|
+
return this;
|
|
87
|
+
}
|
|
88
|
+
summary() {
|
|
89
|
+
return this._description;
|
|
90
|
+
}
|
|
91
|
+
option(name, schema, meta) {
|
|
92
|
+
this.options.push({
|
|
93
|
+
name,
|
|
94
|
+
schema,
|
|
95
|
+
description: meta?.description,
|
|
96
|
+
hasDefault: meta !== undefined && "default" in meta,
|
|
97
|
+
default: meta?.default,
|
|
98
|
+
isSwitch: takesBooleans(schema)
|
|
99
|
+
});
|
|
100
|
+
return this;
|
|
101
|
+
}
|
|
102
|
+
repeated(name, schema, meta) {
|
|
103
|
+
this.options.push({
|
|
104
|
+
name,
|
|
105
|
+
schema,
|
|
106
|
+
description: meta?.description,
|
|
107
|
+
hasDefault: false,
|
|
108
|
+
isSwitch: false,
|
|
109
|
+
repeated: true
|
|
110
|
+
});
|
|
111
|
+
return this;
|
|
112
|
+
}
|
|
113
|
+
arg(name, schema, meta) {
|
|
114
|
+
if (this.variadic) {
|
|
115
|
+
throw new Error(`${this.name}: ${this.variadic.name} takes every remaining argument, so ${name} would never be filled`);
|
|
116
|
+
}
|
|
117
|
+
this.args.push({
|
|
118
|
+
name,
|
|
119
|
+
schema,
|
|
120
|
+
description: meta?.description,
|
|
121
|
+
hasDefault: meta !== undefined && "default" in meta,
|
|
122
|
+
default: meta?.default,
|
|
123
|
+
isSwitch: false
|
|
124
|
+
});
|
|
125
|
+
return this;
|
|
126
|
+
}
|
|
127
|
+
rest(name, schema, meta) {
|
|
128
|
+
if (this.variadic) {
|
|
129
|
+
throw new Error(`${this.name}: ${this.variadic.name} already takes every remaining argument`);
|
|
130
|
+
}
|
|
131
|
+
this.variadic = {
|
|
132
|
+
name,
|
|
133
|
+
schema,
|
|
134
|
+
description: meta?.description,
|
|
135
|
+
hasDefault: false,
|
|
136
|
+
isSwitch: false
|
|
137
|
+
};
|
|
138
|
+
return this;
|
|
139
|
+
}
|
|
140
|
+
allowUnknownOption(allow = true) {
|
|
141
|
+
this.unknownOptions = allow;
|
|
142
|
+
return this;
|
|
143
|
+
}
|
|
144
|
+
allowExcessArguments(allow = true) {
|
|
145
|
+
this.excessArguments = allow;
|
|
146
|
+
return this;
|
|
147
|
+
}
|
|
148
|
+
passThroughOptions(passThrough = true) {
|
|
149
|
+
this.passThrough = passThrough;
|
|
150
|
+
return this;
|
|
151
|
+
}
|
|
152
|
+
use(middleware) {
|
|
153
|
+
if (this.hasAction) {
|
|
154
|
+
throw new Error(`${this.name}: use() must come before action()`);
|
|
155
|
+
}
|
|
156
|
+
this.middleware.push(middleware);
|
|
157
|
+
return this;
|
|
158
|
+
}
|
|
159
|
+
action(action) {
|
|
160
|
+
this._action = action;
|
|
161
|
+
this.hasAction = true;
|
|
162
|
+
return this;
|
|
163
|
+
}
|
|
164
|
+
exec(argv, deps, outer = [], path = this.name) {
|
|
165
|
+
if (this.wantsHelp(argv)) {
|
|
166
|
+
this.help(deps.log, path, deps.ps?.columns());
|
|
167
|
+
return;
|
|
168
|
+
}
|
|
169
|
+
const opts = this.parse(argv);
|
|
170
|
+
const chain = [...outer, ...this.middleware];
|
|
171
|
+
if (chain.length === 0) {
|
|
172
|
+
return this._action(opts, deps);
|
|
173
|
+
}
|
|
174
|
+
let result;
|
|
175
|
+
const run = compose(chain, async (ctx) => {
|
|
176
|
+
result = await this._action(opts, ctx);
|
|
177
|
+
});
|
|
178
|
+
return run(deps).then(() => result);
|
|
179
|
+
}
|
|
180
|
+
wantsHelp(argv) {
|
|
181
|
+
for (let i = 0;i < argv.length; i++) {
|
|
182
|
+
const token = argv[i];
|
|
183
|
+
if (token === "--") {
|
|
184
|
+
return false;
|
|
185
|
+
}
|
|
186
|
+
if (token === "--help" || token === "-h") {
|
|
187
|
+
return true;
|
|
188
|
+
}
|
|
189
|
+
if (this.passThrough && token !== undefined && !this.isValue(argv, i)) {
|
|
190
|
+
return false;
|
|
191
|
+
}
|
|
192
|
+
}
|
|
193
|
+
return false;
|
|
194
|
+
}
|
|
195
|
+
isValue(argv, i) {
|
|
196
|
+
const token = argv[i];
|
|
197
|
+
if (token?.startsWith("-")) {
|
|
198
|
+
return true;
|
|
199
|
+
}
|
|
200
|
+
const previous = argv[i - 1];
|
|
201
|
+
if (previous === undefined || !previous.startsWith("--")) {
|
|
202
|
+
return false;
|
|
203
|
+
}
|
|
204
|
+
return !previous.includes("=") && !this.isSwitch(previous.slice(2));
|
|
205
|
+
}
|
|
206
|
+
isSwitch(name) {
|
|
207
|
+
return this.options.some((option) => option.name === name && option.isSwitch);
|
|
208
|
+
}
|
|
209
|
+
parse(argv) {
|
|
210
|
+
const raw = new Map;
|
|
211
|
+
const repeats = new Map;
|
|
212
|
+
const give = (option, value) => option.repeated ? repeats.set(option.name, [...repeats.get(option.name) ?? [], value]) : raw.set(option.name, value);
|
|
213
|
+
const positional = [];
|
|
214
|
+
for (let i = 0;i < argv.length; i++) {
|
|
215
|
+
const token = argv[i];
|
|
216
|
+
if (token === undefined) {
|
|
217
|
+
continue;
|
|
218
|
+
}
|
|
219
|
+
if (token === "--") {
|
|
220
|
+
positional.push(...argv.slice(i + 1));
|
|
221
|
+
break;
|
|
222
|
+
}
|
|
223
|
+
const stopped = this.passThrough && positional.length > 0;
|
|
224
|
+
if (!token.startsWith("--") || stopped) {
|
|
225
|
+
positional.push(token);
|
|
226
|
+
continue;
|
|
227
|
+
}
|
|
228
|
+
const eq = token.indexOf("=");
|
|
229
|
+
const name = eq === -1 ? token.slice(2) : token.slice(2, eq);
|
|
230
|
+
const option = this.options.find((option) => option.name === name);
|
|
231
|
+
if (option === undefined) {
|
|
232
|
+
if (!this.unknownOptions) {
|
|
233
|
+
throw new Error(`unknown option --${name}`);
|
|
234
|
+
}
|
|
235
|
+
positional.push(token);
|
|
236
|
+
continue;
|
|
237
|
+
}
|
|
238
|
+
if (eq !== -1) {
|
|
239
|
+
give(option, token.slice(eq + 1));
|
|
240
|
+
} else {
|
|
241
|
+
const next = argv[i + 1];
|
|
242
|
+
if (!option.isSwitch && next !== undefined && !next.startsWith("--")) {
|
|
243
|
+
give(option, next);
|
|
244
|
+
i++;
|
|
245
|
+
} else {
|
|
246
|
+
give(option, "true");
|
|
247
|
+
}
|
|
248
|
+
}
|
|
249
|
+
}
|
|
250
|
+
const extra = positional[this.args.length];
|
|
251
|
+
if (extra !== undefined && !this.variadic && !this.excessArguments) {
|
|
252
|
+
throw new Error(`unexpected argument "${extra}"`);
|
|
253
|
+
}
|
|
254
|
+
const out = {};
|
|
255
|
+
this.args.forEach((arg, i) => {
|
|
256
|
+
const value = positional[i];
|
|
257
|
+
if (value === undefined) {
|
|
258
|
+
if (arg.hasDefault) {
|
|
259
|
+
out[arg.name] = arg.default;
|
|
260
|
+
return;
|
|
261
|
+
}
|
|
262
|
+
const missing = absent(arg.schema);
|
|
263
|
+
if (missing !== null) {
|
|
264
|
+
out[arg.name] = missing.value;
|
|
265
|
+
return;
|
|
266
|
+
}
|
|
267
|
+
throw new Error(`missing required argument <${arg.name}>`);
|
|
268
|
+
}
|
|
269
|
+
out[arg.name] = read(arg.schema, value);
|
|
270
|
+
});
|
|
271
|
+
if (this.variadic) {
|
|
272
|
+
const rest = this.variadic;
|
|
273
|
+
out[rest.name] = positional.slice(this.args.length).map((value) => read(rest.schema, value));
|
|
274
|
+
}
|
|
275
|
+
for (const opt of this.options) {
|
|
276
|
+
if (opt.repeated) {
|
|
277
|
+
out[opt.name] = (repeats.get(opt.name) ?? []).map((value) => read(opt.schema, value));
|
|
278
|
+
continue;
|
|
279
|
+
}
|
|
280
|
+
const value = raw.get(opt.name);
|
|
281
|
+
if (value === undefined) {
|
|
282
|
+
if (opt.hasDefault) {
|
|
283
|
+
out[opt.name] = opt.default;
|
|
284
|
+
continue;
|
|
285
|
+
}
|
|
286
|
+
const missing = absent(opt.schema);
|
|
287
|
+
if (missing !== null) {
|
|
288
|
+
out[opt.name] = missing.value;
|
|
289
|
+
continue;
|
|
290
|
+
}
|
|
291
|
+
if (opt.isSwitch) {
|
|
292
|
+
out[opt.name] = false;
|
|
293
|
+
continue;
|
|
294
|
+
}
|
|
295
|
+
throw new Error(`missing required option --${opt.name}`);
|
|
296
|
+
}
|
|
297
|
+
out[opt.name] = read(opt.schema, opt.isSwitch ? onOff(opt.name, value) : value);
|
|
298
|
+
}
|
|
299
|
+
return out;
|
|
300
|
+
}
|
|
301
|
+
optionRow(option) {
|
|
302
|
+
const defaultDescription = option.hasDefault && option.default !== undefined ? color2.dim(` (default: ${JSON.stringify(option.default)})`) : "";
|
|
303
|
+
return [
|
|
304
|
+
`--${option.name}`,
|
|
305
|
+
`${option.description ?? ""}${defaultDescription}`
|
|
306
|
+
];
|
|
307
|
+
}
|
|
308
|
+
help(log, path, width) {
|
|
309
|
+
const args = this.args.map((arg) => arg.hasDefault ? `[${arg.name}]` : `<${arg.name}>`);
|
|
310
|
+
if (this.variadic) {
|
|
311
|
+
args.push(`[${this.variadic.name}...]`);
|
|
312
|
+
}
|
|
313
|
+
const usage = [
|
|
314
|
+
color2.bold(path),
|
|
315
|
+
color2.dim([...args, "[options]"].join(" "))
|
|
316
|
+
].join(" ");
|
|
317
|
+
const lines = [`${color2.bold("Usage:")} ${usage}`];
|
|
318
|
+
if (this._description) {
|
|
319
|
+
lines.push("", ...wrap(this._description, width));
|
|
320
|
+
}
|
|
321
|
+
const named = this.variadic ? [...this.args, { ...this.variadic, name: `${this.variadic.name}...` }] : this.args;
|
|
322
|
+
if (named.length > 0) {
|
|
323
|
+
lines.push("", color2.bold("Arguments:"), ...table(named.map((arg) => [arg.name, arg.description ?? ""]), color2.blue, width));
|
|
324
|
+
}
|
|
325
|
+
lines.push("", color2.bold("Options:"));
|
|
326
|
+
const rows = [
|
|
327
|
+
...this.options.map((option) => this.optionRow(option)),
|
|
328
|
+
["-h, --help", "show this help"]
|
|
329
|
+
];
|
|
330
|
+
lines.push(...table(rows, color2.blue, width));
|
|
331
|
+
log.info(lines.join(`
|
|
332
|
+
`));
|
|
333
|
+
}
|
|
334
|
+
}
|
|
335
|
+
function read(schema, raw) {
|
|
336
|
+
const result = schema["~standard"].validate(raw);
|
|
337
|
+
if (result instanceof Promise) {
|
|
338
|
+
throw new Error(`${schema["~standard"].vendor} validated asynchronously, which is not supported here`);
|
|
339
|
+
}
|
|
340
|
+
if (result.issues === undefined) {
|
|
341
|
+
return result.value;
|
|
342
|
+
}
|
|
343
|
+
const issue = result.issues[0];
|
|
344
|
+
const path = (issue?.path ?? []).map((segment) => String(typeof segment === "object" ? segment.key : segment)).join(".");
|
|
345
|
+
const message = issue?.message ?? "invalid";
|
|
346
|
+
throw new Error(path ? `${path}: ${message}` : message);
|
|
347
|
+
}
|
|
348
|
+
function takesBooleans(schema) {
|
|
349
|
+
const keeps = (value) => {
|
|
350
|
+
const result = schema["~standard"].validate(value);
|
|
351
|
+
if (result instanceof Promise) {
|
|
352
|
+
result.catch(() => {});
|
|
353
|
+
return false;
|
|
354
|
+
}
|
|
355
|
+
return result.issues === undefined && result.value === value;
|
|
356
|
+
};
|
|
357
|
+
return keeps(true) && keeps(false) && !keeps("true");
|
|
358
|
+
}
|
|
359
|
+
function onOff(name, raw) {
|
|
360
|
+
if (raw !== "true" && raw !== "false") {
|
|
361
|
+
throw new Error(`--${name}: expected true or false, got "${raw}"`);
|
|
362
|
+
}
|
|
363
|
+
return raw === "true";
|
|
364
|
+
}
|
|
365
|
+
function absent(schema) {
|
|
366
|
+
const result = schema["~standard"].validate(undefined);
|
|
367
|
+
if (result instanceof Promise || result.issues !== undefined) {
|
|
368
|
+
return null;
|
|
369
|
+
}
|
|
370
|
+
return { value: result.value };
|
|
371
|
+
}
|
|
372
|
+
|
|
373
|
+
// cmd/cli.ts
|
|
374
|
+
class Cli {
|
|
375
|
+
name;
|
|
376
|
+
cmds = new Map;
|
|
377
|
+
middleware = [];
|
|
378
|
+
_description = "";
|
|
379
|
+
_fallback;
|
|
380
|
+
constructor(name) {
|
|
381
|
+
this.name = name;
|
|
382
|
+
}
|
|
383
|
+
description(description) {
|
|
384
|
+
this._description = description;
|
|
385
|
+
return this;
|
|
386
|
+
}
|
|
387
|
+
use(middleware) {
|
|
388
|
+
if (this.cmds.size > 0) {
|
|
389
|
+
throw new Error(`${this.name}: use() must come before command()`);
|
|
390
|
+
}
|
|
391
|
+
this.middleware.push(middleware);
|
|
392
|
+
return this;
|
|
393
|
+
}
|
|
394
|
+
command(name) {
|
|
395
|
+
const command = new Command(name);
|
|
396
|
+
this.cmds.set(name, command);
|
|
397
|
+
return command;
|
|
398
|
+
}
|
|
399
|
+
group(name) {
|
|
400
|
+
const group = new Cli(name);
|
|
401
|
+
this.cmds.set(name, group);
|
|
402
|
+
return group;
|
|
403
|
+
}
|
|
404
|
+
fallback(name) {
|
|
405
|
+
this._fallback = name;
|
|
406
|
+
return this;
|
|
407
|
+
}
|
|
408
|
+
mount(name, sub) {
|
|
409
|
+
this.cmds.set(name, sub);
|
|
410
|
+
return this;
|
|
411
|
+
}
|
|
412
|
+
run(deps, argv) {
|
|
413
|
+
const ps = deps.ps ?? new NodePs;
|
|
414
|
+
const full = { ...deps, log: deps.log ?? new ConsoleLogger, ps };
|
|
415
|
+
try {
|
|
416
|
+
const out = this.exec(argv ?? ps.args, full, []);
|
|
417
|
+
return out instanceof Promise ? out.catch((error) => this.fail(full, error)) : out;
|
|
418
|
+
} catch (error) {
|
|
419
|
+
return this.fail(full, error);
|
|
420
|
+
}
|
|
421
|
+
}
|
|
422
|
+
exec(argv, deps, outer = [], path = this.name) {
|
|
423
|
+
const [name, ...rest] = argv;
|
|
424
|
+
if (name === "--help" || name === "-h") {
|
|
425
|
+
return this.help(deps, path);
|
|
426
|
+
}
|
|
427
|
+
const cmd = name === undefined ? undefined : this.cmds.get(name);
|
|
428
|
+
if (!cmd) {
|
|
429
|
+
const fallback = this._fallback === undefined ? undefined : this.cmds.get(this._fallback);
|
|
430
|
+
return fallback ? fallback.exec(argv, deps, [...outer, ...this.middleware], path) : this.help(deps, path);
|
|
431
|
+
}
|
|
432
|
+
return cmd.exec(rest, deps, [...outer, ...this.middleware], `${path} ${name}`);
|
|
433
|
+
}
|
|
434
|
+
summary() {
|
|
435
|
+
return this._description;
|
|
436
|
+
}
|
|
437
|
+
fail(deps, error) {
|
|
438
|
+
deps.log.error(`error: ${error instanceof Error ? error.message : error}`);
|
|
439
|
+
deps.ps.exit(1);
|
|
440
|
+
}
|
|
441
|
+
help(deps, path) {
|
|
442
|
+
const rows = [...this.cmds].map(([name, command]) => {
|
|
443
|
+
const fallback = name === this._fallback ? color3.dim("(default)") : "";
|
|
444
|
+
return [name, [command.summary(), fallback].filter(Boolean).join(" ")];
|
|
445
|
+
});
|
|
446
|
+
const lines = [
|
|
447
|
+
`${color3.bold("Usage:")} ${color3.bold(path)} ${color3.dim("<command> [options]")}`,
|
|
448
|
+
"",
|
|
449
|
+
color3.bold("Commands:"),
|
|
450
|
+
...table(rows, (name) => color3.bold(color3.blue(name)), deps.ps.columns()),
|
|
451
|
+
"",
|
|
452
|
+
color3.dim(`Run \`${path} <command> --help\` for a command's options.`)
|
|
453
|
+
];
|
|
454
|
+
deps.log.info(lines.join(`
|
|
455
|
+
`));
|
|
456
|
+
}
|
|
457
|
+
}
|
|
458
|
+
function cli(name) {
|
|
459
|
+
return new Cli(name);
|
|
460
|
+
}
|
|
461
|
+
// cmd/timed.ts
|
|
462
|
+
import { color as color4 } from "../log/index.js";
|
|
463
|
+
import { Stopwatch, SystemClock } from "../time/index.js";
|
|
464
|
+
function timed(clock = new SystemClock) {
|
|
465
|
+
return async (ctx, next) => {
|
|
466
|
+
const stopwatch = new Stopwatch(clock);
|
|
467
|
+
stopwatch.start();
|
|
468
|
+
ctx.ps.once("exit", () => {
|
|
469
|
+
ctx.log.error(color4.dim(`done in ${stopwatch.elapsed().human()}`));
|
|
470
|
+
});
|
|
471
|
+
await next(ctx);
|
|
472
|
+
};
|
|
473
|
+
}
|
|
474
|
+
export {
|
|
475
|
+
cli,
|
|
476
|
+
timed
|
|
477
|
+
};
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
/** Runs whatever is left of the chain, with the context it should see. */
|
|
2
|
+
export type Next<C> = (ctx: C) => Promise<void>;
|
|
3
|
+
/**
|
|
4
|
+
* Wraps an action: do some work, hand a context to `next`, and do more once it
|
|
5
|
+
* comes back. `Out` is what everything downstream sees, so a middleware that
|
|
6
|
+
* contributes to the context widens its type as well as its value.
|
|
7
|
+
*
|
|
8
|
+
* Middleware runs after `--help` and after options are parsed, so it only ever
|
|
9
|
+
* wraps the action itself: asking for help never pays for the setup.
|
|
10
|
+
*/
|
|
11
|
+
export type Middleware<In, Out = In> = (ctx: In, next: Next<Out>) => Promise<void>;
|
|
12
|
+
/** A middleware of any context types, as a chain holds it. */
|
|
13
|
+
export type AnyMiddleware = Middleware<never, never>;
|
|
14
|
+
/** Folds a chain into one call, innermost last. */
|
|
15
|
+
export declare function compose(middleware: AnyMiddleware[], action: (ctx: unknown) => Promise<void>): (ctx: unknown) => Promise<void>;
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { type Clock } from "../time/index.js";
|
|
2
|
+
import type { Deps } from "./deps";
|
|
3
|
+
import type { Middleware } from "./middleware";
|
|
4
|
+
/**
|
|
5
|
+
* Says how long a command took, on stderr, as the process ends. That is
|
|
6
|
+
* after the action returns, or whenever something ends the process sooner,
|
|
7
|
+
* since a command that sets its exit code with `ps.exit` never returns to a
|
|
8
|
+
* middleware to report it.
|
|
9
|
+
*
|
|
10
|
+
* ```ts
|
|
11
|
+
* program.command("check").use(timed()).action(...);
|
|
12
|
+
* // ... done in 1m 12s
|
|
13
|
+
* ```
|
|
14
|
+
*/
|
|
15
|
+
export declare function timed<C extends Deps>(clock?: Clock): Middleware<C>;
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
import type { AsyncResource } from "../disposable/index.js";
|
|
2
|
+
import type { CredentialSource } from "./credential-source";
|
|
3
|
+
/** What `CredentialProxy.listen` forwards, and which key it puts in. */
|
|
4
|
+
export interface CredentialProxyOptions {
|
|
5
|
+
/**
|
|
6
|
+
* Where every request goes: an `https://` origin, with a path each
|
|
7
|
+
* request's own is put under when it has one, such as
|
|
8
|
+
* `https://api.openai.com/v1`. Nothing else is ever reached.
|
|
9
|
+
*/
|
|
10
|
+
upstream: string;
|
|
11
|
+
/** The credential's name in the source, such as `ANTHROPIC_API_KEY`. */
|
|
12
|
+
credential: string;
|
|
13
|
+
/**
|
|
14
|
+
* The header the key travels in, such as `x-api-key` for Anthropic or
|
|
15
|
+
* `authorization` for OpenAI. The client sends its placeholder there, and
|
|
16
|
+
* the proxy puts the real key there in its place.
|
|
17
|
+
*/
|
|
18
|
+
header: string;
|
|
19
|
+
/** The word before the key in that header, such as `Bearer`; none by default. */
|
|
20
|
+
scheme?: string;
|
|
21
|
+
}
|
|
22
|
+
/**
|
|
23
|
+
* A loopback HTTP proxy that keeps an API key from the program it serves,
|
|
24
|
+
* such as an agent's CLI. The program gets `url` as its provider's base URL
|
|
25
|
+
* and `placeholder` as its key; the proxy forwards each of its requests to
|
|
26
|
+
* the one upstream with the placeholder swapped for the real key, which it
|
|
27
|
+
* reads from its source on every request, so a rotated key needs no
|
|
28
|
+
* restart. The program never holds the key, so it cannot print, log or send
|
|
29
|
+
* it anywhere.
|
|
30
|
+
*
|
|
31
|
+
* It listens on 127.0.0.1 alone, on a free port, and refuses with a 401,
|
|
32
|
+
* reaching no upstream, any request without its own placeholder, which is
|
|
33
|
+
* random for each proxy, so another local process, or another task's agent,
|
|
34
|
+
* cannot spend the key through it. It never follows a redirect, so the key
|
|
35
|
+
* goes to the upstream origin and nowhere else, and it passes responses
|
|
36
|
+
* through as they stream, server-sent events and compressed bodies alike.
|
|
37
|
+
* No response, error or log of its own ever holds the key.
|
|
38
|
+
*
|
|
39
|
+
* The placeholder is only as private as the program's environment: on a
|
|
40
|
+
* machine where the program runs as the proxy's own user, make the process
|
|
41
|
+
* holding the key undumpable (`makeUndumpable()` from `webappwiz/system`),
|
|
42
|
+
* or run the program in a container.
|
|
43
|
+
*/
|
|
44
|
+
export declare class CredentialProxy implements AsyncResource {
|
|
45
|
+
private readonly server;
|
|
46
|
+
/** The base URL to hand the program, as `http://127.0.0.1:<port>`. */
|
|
47
|
+
readonly url: string;
|
|
48
|
+
/** The key to hand the program in place of the real one. */
|
|
49
|
+
readonly placeholder: string;
|
|
50
|
+
private constructor();
|
|
51
|
+
/** Starts a proxy for one credential, reading it from `source`. */
|
|
52
|
+
static listen(source: CredentialSource, opts: CredentialProxyOptions): CredentialProxy;
|
|
53
|
+
/** Stops listening and cuts every request still streaming. */
|
|
54
|
+
disposeAsync(): Promise<void>;
|
|
55
|
+
}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Somewhere a credential's value can come from, by its environment variable
|
|
3
|
+
* name. `Credentials` reads a list of them in order, and the caller picks
|
|
4
|
+
* which: the environment and a `.env` file where the app is deployed, the
|
|
5
|
+
* system's store on a person's machine.
|
|
6
|
+
*/
|
|
7
|
+
export interface CredentialSource {
|
|
8
|
+
/** What a person calls it, as in "the environment" or "the macOS Keychain". */
|
|
9
|
+
readonly label: string;
|
|
10
|
+
/** The value it has for `name`, or undefined when it has none. */
|
|
11
|
+
get(name: string): Promise<string | undefined>;
|
|
12
|
+
}
|
|
13
|
+
/**
|
|
14
|
+
* `name`, when it can be an environment variable's: letters, digits and
|
|
15
|
+
* `_`, not starting with a digit. Throws otherwise, so a store never keeps a
|
|
16
|
+
* value no environment could hold, and its own bookkeeping, under names
|
|
17
|
+
* that cannot be these, is safe from a credential's.
|
|
18
|
+
*/
|
|
19
|
+
export declare function credentialName(name: string): string;
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import type { CredentialSource } from "./credential-source";
|
|
2
|
+
/**
|
|
3
|
+
* An app's credentials, each named the way its environment variable is, read
|
|
4
|
+
* from the sources the caller lists, first one with a value wins. Which
|
|
5
|
+
* sources is the caller's choice: the environment and a `.env` file where the
|
|
6
|
+
* app is deployed, only the system's store on a person's machine, so a stray
|
|
7
|
+
* export or a forgotten `.env` is never what a dev run reads. A source need
|
|
8
|
+
* not list what it holds, so a caller names what it needs; a `SecretStore`
|
|
9
|
+
* can also list its own.
|
|
10
|
+
*
|
|
11
|
+
* It is a source itself, so lists compose: a group of sources is one entry
|
|
12
|
+
* in another list, and any object with a `label` and a `get`, such as one
|
|
13
|
+
* over a hosted secrets manager, is a source too.
|
|
14
|
+
*/
|
|
15
|
+
export declare class Credentials implements CredentialSource {
|
|
16
|
+
readonly sources: readonly CredentialSource[];
|
|
17
|
+
readonly label: string;
|
|
18
|
+
constructor(sources: readonly CredentialSource[]);
|
|
19
|
+
/** The value of `name`, or undefined when no source has it. */
|
|
20
|
+
get(name: string): Promise<string | undefined>;
|
|
21
|
+
/**
|
|
22
|
+
* The value of `name`, or an error saying where it looked. The error never
|
|
23
|
+
* holds a value, so it is safe to show anyone.
|
|
24
|
+
*/
|
|
25
|
+
require(name: string): Promise<string>;
|
|
26
|
+
/** The source `name` would be read from, without reading it out; undefined when none has it. */
|
|
27
|
+
source(name: string): Promise<CredentialSource | undefined>;
|
|
28
|
+
}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { type Fs } from "../system/index.js";
|
|
2
|
+
import type { CredentialSource } from "./credential-source";
|
|
3
|
+
/** Where `DotenvFile` reads; the real filesystem by default. */
|
|
4
|
+
export interface DotenvFileOptions {
|
|
5
|
+
fs?: Fs;
|
|
6
|
+
}
|
|
7
|
+
/**
|
|
8
|
+
* A `.env` file of `NAME=value` lines, read once, on the first `get`. A
|
|
9
|
+
* missing file has nothing, rather than failing, so a deploy without one
|
|
10
|
+
* falls through to the next source. Values may be quoted, a line may start
|
|
11
|
+
* with `export`, and `#` starts a comment outside quotes. Variables are not
|
|
12
|
+
* expanded.
|
|
13
|
+
*/
|
|
14
|
+
export declare class DotenvFile implements CredentialSource {
|
|
15
|
+
readonly path: string;
|
|
16
|
+
readonly label: string;
|
|
17
|
+
private fs;
|
|
18
|
+
private values?;
|
|
19
|
+
constructor(path: string, opts?: DotenvFileOptions);
|
|
20
|
+
get(name: string): Promise<string | undefined>;
|
|
21
|
+
private read;
|
|
22
|
+
}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { type Ps } from "../system/index.js";
|
|
2
|
+
import type { CredentialSource } from "./credential-source";
|
|
3
|
+
/** Where `Environment` reads; the real process by default. */
|
|
4
|
+
export interface EnvironmentOptions {
|
|
5
|
+
ps?: Ps;
|
|
6
|
+
}
|
|
7
|
+
/**
|
|
8
|
+
* The process's environment variables, the way CI, containers and hosting
|
|
9
|
+
* platforms hand a deployed app its secrets. An empty value counts as none.
|
|
10
|
+
* Bun loads a project's `.env` files into the environment itself, so under
|
|
11
|
+
* Bun this reads them too.
|
|
12
|
+
*/
|
|
13
|
+
export declare class Environment implements CredentialSource {
|
|
14
|
+
readonly label = "the environment";
|
|
15
|
+
private ps;
|
|
16
|
+
constructor(opts?: EnvironmentOptions);
|
|
17
|
+
get(name: string): Promise<string | undefined>;
|
|
18
|
+
}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
export { CredentialProxy, type CredentialProxyOptions, } from "./credential-proxy";
|
|
2
|
+
export { type CredentialSource, credentialName } from "./credential-source";
|
|
3
|
+
export { Credentials } from "./credentials";
|
|
4
|
+
export { DotenvFile, type DotenvFileOptions } from "./dotenv-file";
|
|
5
|
+
export { Environment, type EnvironmentOptions } from "./environment";
|
|
6
|
+
export { MemorySecretStore } from "./memory-secret-store";
|
|
7
|
+
export type { SecretStore } from "./secret-store";
|
|
8
|
+
export { type ForProjectOptions, projectName, SystemSecretStore, } from "./system-secret-store";
|