windows-development-sandbox 1.5.0 → 1.7.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/README.md +1 -0
- package/config.example.json +17 -1
- package/dist/cli/args.d.ts +13 -2
- package/dist/cli/args.js +95 -24
- package/dist/cli/commands/accounts.js +45 -17
- package/dist/cli/commands/context.d.ts +2 -0
- package/dist/cli/commands/context.js +9 -2
- package/dist/cli/commands/data/clean.js +32 -9
- package/dist/cli/commands/index.d.ts +1 -0
- package/dist/cli/commands/index.js +1 -0
- package/dist/cli/commands/launch/add-root.d.ts +3 -2
- package/dist/cli/commands/launch/add-root.js +11 -10
- package/dist/cli/commands/launch/launch.js +57 -4
- package/dist/cli/commands/launch/prepare.js +3 -1
- package/dist/cli/commands/maintenance/audit.js +1 -1
- package/dist/cli/commands/maintenance/clean.d.ts +1 -1
- package/dist/cli/commands/maintenance/clean.js +17 -3
- package/dist/cli/commands/maintenance/config.d.ts +1 -1
- package/dist/cli/commands/maintenance/config.js +112 -10
- package/dist/cli/commands/maintenance/doctor.d.ts +1 -1
- package/dist/cli/commands/maintenance/doctor.js +2 -4
- package/dist/cli/commands/maintenance/migrate.d.ts +2 -1
- package/dist/cli/commands/maintenance/migrate.js +19 -4
- package/dist/cli/commands/maintenance/sync.js +2 -0
- package/dist/cli/commands/maintenance/update.d.ts +2 -0
- package/dist/cli/commands/maintenance/update.js +27 -4
- package/dist/cli/commands/projects/here.js +12 -7
- package/dist/cli/commands/projects/projects.js +26 -17
- package/dist/cli/commands/registry.js +7 -0
- package/dist/cli/commands/repair/checks/agents.d.ts +2 -0
- package/dist/cli/commands/repair/checks/agents.js +70 -0
- package/dist/cli/commands/repair/checks/common.d.ts +8 -0
- package/dist/cli/commands/repair/checks/common.js +22 -0
- package/dist/cli/commands/repair/checks/data.d.ts +2 -0
- package/dist/cli/commands/repair/checks/data.js +241 -0
- package/dist/cli/commands/repair/checks/index.d.ts +2 -0
- package/dist/cli/commands/repair/checks/index.js +20 -0
- package/dist/cli/commands/repair/checks/install.d.ts +5 -0
- package/dist/cli/commands/repair/checks/install.js +318 -0
- package/dist/cli/commands/repair/checks/machine.d.ts +2 -0
- package/dist/cli/commands/repair/checks/machine.js +232 -0
- package/dist/cli/commands/repair/checks/network.d.ts +6 -0
- package/dist/cli/commands/repair/checks/network.js +60 -0
- package/dist/cli/commands/repair/checks/pc.d.ts +4 -0
- package/dist/cli/commands/repair/checks/pc.js +55 -0
- package/dist/cli/commands/repair/checks/sandbox.d.ts +2 -0
- package/dist/cli/commands/repair/checks/sandbox.js +267 -0
- package/dist/cli/commands/repair/checks/settings.d.ts +2 -0
- package/dist/cli/commands/repair/checks/settings.js +169 -0
- package/dist/cli/commands/repair/checks/vpn.d.ts +2 -0
- package/dist/cli/commands/repair/checks/vpn.js +53 -0
- package/dist/cli/commands/repair/engine.d.ts +32 -0
- package/dist/cli/commands/repair/engine.js +127 -0
- package/dist/cli/commands/repair/env.d.ts +7 -0
- package/dist/cli/commands/repair/env.js +49 -0
- package/dist/cli/commands/repair/index.d.ts +1 -9
- package/dist/cli/commands/repair/index.js +2 -54
- package/dist/cli/commands/repair/log.d.ts +17 -0
- package/dist/cli/commands/repair/log.js +82 -0
- package/dist/cli/commands/repair/printer.d.ts +32 -0
- package/dist/cli/commands/repair/printer.js +132 -0
- package/dist/cli/commands/repair/run.d.ts +33 -0
- package/dist/cli/commands/repair/run.js +133 -0
- package/dist/cli/commands/repair/types.d.ts +97 -9
- package/dist/cli/commands/repair/types.js +11 -7
- package/dist/cli/commands/resume.js +2 -2
- package/dist/cli/commands/sessions/list.js +5 -2
- package/dist/cli/commands/sessions/status.d.ts +2 -0
- package/dist/cli/commands/sessions/status.js +27 -6
- package/dist/cli/commands/setup/index.d.ts +5 -0
- package/dist/cli/commands/setup/index.js +25 -1
- package/dist/cli/commands/storage/index.d.ts +2 -0
- package/dist/cli/commands/storage/index.js +2 -0
- package/dist/cli/commands/storage/offer.d.ts +3 -0
- package/dist/cli/commands/storage/offer.js +85 -0
- package/dist/cli/commands/storage/storage.d.ts +8 -0
- package/dist/cli/commands/storage/storage.js +171 -0
- package/dist/cli/commands/user-config.js +1 -1
- package/dist/cli/commands/vpn.d.ts +4 -0
- package/dist/cli/commands/vpn.js +75 -0
- package/dist/cli/commands/web.d.ts +4 -0
- package/dist/cli/commands/web.js +95 -0
- package/dist/cli/history.js +1 -1
- package/dist/cli/index.js +46 -3
- package/dist/cli/manifest.d.ts +303 -29
- package/dist/cli/manifest.js +173 -43
- package/dist/cli/menu/add-agent.d.ts +47 -0
- package/dist/cli/menu/add-agent.js +168 -0
- package/dist/cli/menu/apps.d.ts +31 -2
- package/dist/cli/menu/apps.js +44 -5
- package/dist/cli/menu/command-fields.d.ts +18 -0
- package/dist/cli/menu/command-fields.js +61 -0
- package/dist/cli/menu/command-form.d.ts +22 -0
- package/dist/cli/menu/command-form.js +169 -46
- package/dist/cli/menu/data-folder.d.ts +18 -0
- package/dist/cli/menu/data-folder.js +99 -0
- package/dist/cli/menu/menu.d.ts +1 -1
- package/dist/cli/menu/menu.js +11 -8
- package/dist/cli/menu/pages/accounts-page.js +55 -24
- package/dist/cli/menu/pages/agents-page.d.ts +66 -0
- package/dist/cli/menu/pages/agents-page.js +338 -0
- package/dist/cli/menu/pages/apps-page.js +1 -2
- package/dist/cli/menu/pages/list-page.d.ts +16 -3
- package/dist/cli/menu/pages/list-page.js +40 -8
- package/dist/cli/menu/pages/maintenance-page.d.ts +9 -0
- package/dist/cli/menu/pages/maintenance-page.js +161 -72
- package/dist/cli/menu/pages/sandbox-page.d.ts +3 -0
- package/dist/cli/menu/pages/sandbox-page.js +132 -43
- package/dist/cli/menu/pages/sessions-page.d.ts +4 -0
- package/dist/cli/menu/pages/sessions-page.js +41 -25
- package/dist/cli/menu/pages/settings-page.d.ts +8 -4
- package/dist/cli/menu/pages/settings-page.js +36 -13
- package/dist/cli/menu/settings/categories.d.ts +2 -0
- package/dist/cli/menu/settings/categories.js +19 -44
- package/dist/cli/menu/settings/collections/collection-editor.d.ts +7 -1
- package/dist/cli/menu/settings/collections/collection-editor.js +12 -8
- package/dist/cli/menu/settings/collections/map-editor.js +5 -1
- package/dist/cli/menu/settings/collections/object-list-editor.js +2 -2
- package/dist/cli/menu/settings/collections/object-map-editor.js +2 -2
- package/dist/cli/menu/settings/collections/string-list-editor.d.ts +11 -1
- package/dist/cli/menu/settings/collections/string-list-editor.js +23 -0
- package/dist/cli/menu/settings/index.d.ts +1 -1
- package/dist/cli/menu/settings/index.js +1 -1
- package/dist/cli/menu/settings/object-editor.d.ts +5 -1
- package/dist/cli/menu/settings/object-editor.js +15 -4
- package/dist/cli/menu/settings/path-kind.d.ts +20 -0
- package/dist/cli/menu/settings/path-kind.js +44 -0
- package/dist/cli/menu/settings/schema-node.d.ts +9 -0
- package/dist/cli/menu/settings/schema-node.js +26 -0
- package/dist/cli/menu/settings/value-editor.d.ts +5 -0
- package/dist/cli/menu/settings/value-editor.js +51 -18
- package/dist/cli/menu/several.js +7 -5
- package/dist/cli/menu/shell.d.ts +37 -10
- package/dist/cli/menu/shell.js +90 -10
- package/dist/cli/menu/vpn-login.d.ts +16 -0
- package/dist/cli/menu/vpn-login.js +66 -0
- package/dist/cli/output/print.d.ts +2 -0
- package/dist/cli/output/print.js +8 -1
- package/dist/cli/services/accounts-service.d.ts +2 -0
- package/dist/cli/services/accounts-service.js +2 -2
- package/dist/cli/services/health-service.d.ts +0 -6
- package/dist/cli/services/health-service.js +5 -42
- package/dist/cli/services/index.d.ts +3 -1
- package/dist/cli/services/index.js +3 -1
- package/dist/cli/services/migrate-service.js +1 -1
- package/dist/cli/services/update-service.d.ts +2 -0
- package/dist/cli/services/update-service.js +13 -6
- package/dist/cli/services/vpn-service.d.ts +28 -0
- package/dist/cli/services/vpn-service.js +46 -0
- package/dist/cli/services/web-service.d.ts +22 -0
- package/dist/cli/services/web-service.js +111 -0
- package/dist/cli/tui/app.d.ts +6 -3
- package/dist/cli/tui/app.js +12 -5
- package/dist/cli/tui/dialogs/path-listing.d.ts +43 -0
- package/dist/cli/tui/dialogs/path-listing.js +127 -0
- package/dist/cli/tui/dialogs/path-picker.d.ts +67 -0
- package/dist/cli/tui/dialogs/path-picker.js +423 -0
- package/dist/cli/tui/dialogs/text-screen.d.ts +6 -0
- package/dist/cli/tui/dialogs/text-screen.js +10 -3
- package/dist/cli/tui/frame.d.ts +7 -10
- package/dist/cli/tui/frame.js +19 -10
- package/dist/cli/tui/index.d.ts +4 -3
- package/dist/cli/tui/index.js +2 -1
- package/dist/cli/tui/list/list-screen.d.ts +14 -2
- package/dist/cli/tui/list/list-screen.js +68 -32
- package/dist/cli/tui/list/list-types.d.ts +8 -4
- package/dist/cli/tui/nav.d.ts +29 -0
- package/dist/cli/tui/nav.js +67 -0
- package/dist/cli/validate.d.ts +1 -1
- package/dist/cli/validate.js +3 -3
- package/dist/cli/version.d.ts +2 -0
- package/dist/cli/version.js +11 -0
- package/dist/core/config/defaults.js +5 -1
- package/dist/core/config/loader.js +12 -2
- package/dist/core/local-config/overrides.js +1 -0
- package/dist/core/prompt.d.ts +19 -0
- package/dist/core/prompt.js +43 -3
- package/dist/core/schema/common.d.ts +6 -0
- package/dist/core/schema/common.js +8 -0
- package/dist/core/schema/config.d.ts +23 -0
- package/dist/core/schema/config.js +10 -1
- package/dist/core/schema/harness.d.ts +1 -0
- package/dist/core/schema/harness.js +8 -2
- package/dist/core/schema/index.d.ts +3 -1
- package/dist/core/schema/index.js +3 -1
- package/dist/core/schema/profile.d.ts +1 -0
- package/dist/core/schema/profile.js +3 -0
- package/dist/core/schema/redact.d.ts +13 -0
- package/dist/core/schema/redact.js +75 -0
- package/dist/core/schema/sandbox.js +1 -0
- package/dist/core/schema/vpn.d.ts +17 -0
- package/dist/core/schema/vpn.js +22 -0
- package/dist/core/schema/web.d.ts +6 -0
- package/dist/core/schema/web.js +14 -0
- package/dist/core/types.d.ts +26 -0
- package/dist/guest/agents/agent-files.d.ts +49 -0
- package/dist/guest/agents/agent-files.js +63 -0
- package/dist/guest/agents/agent-installer.js +2 -9
- package/dist/guest/agents/local-state.d.ts +12 -0
- package/dist/guest/agents/local-state.js +198 -0
- package/dist/guest/agents/sbx-agent.d.ts +2 -0
- package/dist/guest/agents/sbx-agent.js +35 -0
- package/dist/guest/boot/boot.d.ts +4 -0
- package/dist/guest/boot/boot.js +50 -11
- package/dist/guest/daemon/daemon.js +4 -1
- package/dist/guest/daemon/exec.js +2 -1
- package/dist/guest/daemon/idle-shutdown.js +2 -0
- package/dist/guest/daemon/sessions.js +4 -1
- package/dist/guest/entries/agent.d.ts +1 -0
- package/dist/guest/entries/agent.js +10 -0
- package/dist/guest/entries/daemon.js +2 -0
- package/dist/guest/runtime/csc.d.ts +1 -0
- package/dist/guest/runtime/csc.js +1 -0
- package/dist/guest/runtime/secrets.d.ts +12 -0
- package/dist/guest/runtime/secrets.js +63 -0
- package/dist/guest/setup/claude-profile.d.ts +2 -1
- package/dist/guest/setup/claude-profile.js +12 -1
- package/dist/guest/setup/environment.d.ts +6 -0
- package/dist/guest/setup/environment.js +56 -6
- package/dist/guest/setup/path-plan.d.ts +32 -0
- package/dist/guest/setup/path-plan.js +67 -0
- package/dist/guest/setup/shell-path.d.ts +1 -0
- package/dist/guest/setup/shell-path.js +22 -0
- package/dist/guest/toolchains/languages/python.js +1 -1
- package/dist/guest/toolchains/runtimes.js +2 -2
- package/dist/guest/vpn/index.d.ts +1 -0
- package/dist/guest/vpn/index.js +1 -0
- package/dist/guest/vpn/openvpn.d.ts +9 -0
- package/dist/guest/vpn/openvpn.js +47 -0
- package/dist/guest/vpn/tunnel.d.ts +17 -0
- package/dist/guest/vpn/tunnel.js +78 -0
- package/dist/guest/vpn/vpn.d.ts +6 -0
- package/dist/guest/vpn/vpn.js +126 -0
- package/dist/host/channel/attach.d.ts +3 -1
- package/dist/host/channel/attach.js +1 -1
- package/dist/host/channel/channel.d.ts +7 -0
- package/dist/host/channel/channel.js +26 -2
- package/dist/host/health/acl-read.d.ts +17 -0
- package/dist/host/health/acl-read.js +45 -0
- package/dist/host/health/config-backup.d.ts +11 -0
- package/dist/host/health/config-backup.js +73 -0
- package/dist/host/health/index.d.ts +6 -0
- package/dist/host/health/index.js +7 -0
- package/dist/host/health/install-state.d.ts +33 -0
- package/dist/host/health/install-state.js +110 -0
- package/dist/host/health/path-copies.d.ts +32 -0
- package/dist/host/health/path-copies.js +82 -0
- package/dist/host/health/stale.d.ts +45 -0
- package/dist/host/health/stale.js +120 -0
- package/dist/host/health/system.d.ts +37 -0
- package/dist/host/health/system.js +87 -0
- package/dist/host/install/copies.d.ts +13 -0
- package/dist/host/install/copies.js +63 -0
- package/dist/host/install/index.d.ts +1 -0
- package/dist/host/install/index.js +1 -0
- package/dist/host/launch/generate.js +25 -1
- package/dist/host/launch/session-file.js +4 -1
- package/dist/host/launch/stage.js +1 -1
- package/dist/host/migrate/backup.js +3 -0
- package/dist/host/migrate/migrations/config-file.d.ts +2 -0
- package/dist/host/migrate/migrations/config-file.js +7 -0
- package/dist/host/migrate/migrations/follow-machine-storage.js +9 -1
- package/dist/host/migrate/migrations/pin-storage-root.d.ts +4 -0
- package/dist/host/migrate/migrations/pin-storage-root.js +46 -0
- package/dist/host/migrate/migrations/unpin-config-defaults.js +4 -1
- package/dist/host/migrate/registry.js +2 -1
- package/dist/host/profile/accounts.d.ts +25 -1
- package/dist/host/profile/accounts.js +96 -13
- package/dist/host/profile/agent-accounts.d.ts +5 -1
- package/dist/host/profile/agent-accounts.js +35 -5
- package/dist/host/profile/index.d.ts +2 -1
- package/dist/host/profile/index.js +1 -0
- package/dist/host/profile/plugin-share.d.ts +26 -0
- package/dist/host/profile/plugin-share.js +146 -0
- package/dist/host/projects/join.d.ts +7 -1
- package/dist/host/projects/join.js +21 -4
- package/dist/host/projects/registry.d.ts +16 -10
- package/dist/host/projects/registry.js +74 -6
- package/dist/host/sandbox/platform.d.ts +2 -0
- package/dist/host/sandbox/platform.js +21 -2
- package/dist/host/secrets/index.d.ts +2 -0
- package/dist/host/secrets/index.js +2 -0
- package/dist/host/secrets/launch-secrets.d.ts +17 -0
- package/dist/host/secrets/launch-secrets.js +93 -0
- package/dist/host/secrets/secret-store.d.ts +25 -0
- package/dist/host/secrets/secret-store.js +89 -0
- package/dist/host/sharing/acl.d.ts +16 -2
- package/dist/host/sharing/acl.js +35 -10
- package/dist/host/sharing/current.js +11 -2
- package/dist/host/sharing/doctor.d.ts +2 -0
- package/dist/host/sharing/doctor.js +44 -0
- package/dist/host/sharing/group-access.d.ts +6 -0
- package/dist/host/sharing/group-access.js +24 -0
- package/dist/host/sharing/index.d.ts +2 -1
- package/dist/host/sharing/index.js +2 -1
- package/dist/host/sharing/lifecycle.d.ts +8 -2
- package/dist/host/sharing/lifecycle.js +16 -7
- package/dist/host/storage/cleanup.d.ts +2 -0
- package/dist/host/storage/cleanup.js +2 -1
- package/dist/host/storage/history.d.ts +21 -0
- package/dist/host/storage/history.js +49 -0
- package/dist/host/storage/index.d.ts +4 -0
- package/dist/host/storage/index.js +4 -0
- package/dist/host/storage/move.d.ts +95 -0
- package/dist/host/storage/move.js +384 -0
- package/dist/host/storage/offer.d.ts +11 -0
- package/dist/host/storage/offer.js +36 -0
- package/dist/host/storage/root.d.ts +18 -0
- package/dist/host/storage/root.js +77 -0
- package/dist/host/tools/windows-terminal.d.ts +2 -0
- package/dist/host/tools/windows-terminal.js +23 -5
- package/dist/host/update/index.d.ts +1 -1
- package/dist/host/update/index.js +1 -1
- package/dist/host/update/notice.d.ts +2 -0
- package/dist/host/update/notice.js +13 -1
- package/dist/host/update/update-state.d.ts +6 -0
- package/dist/host/update/update-state.js +2 -0
- package/dist/host/update/updater.d.ts +19 -0
- package/dist/host/update/updater.js +88 -12
- package/dist/host/vpn/index.d.ts +4 -0
- package/dist/host/vpn/index.js +4 -0
- package/dist/host/vpn/login.d.ts +24 -0
- package/dist/host/vpn/login.js +79 -0
- package/dist/host/vpn/nordvpn.d.ts +21 -0
- package/dist/host/vpn/nordvpn.js +77 -0
- package/dist/host/vpn/prepare.d.ts +17 -0
- package/dist/host/vpn/prepare.js +77 -0
- package/dist/host/vpn/status.d.ts +12 -0
- package/dist/host/vpn/status.js +53 -0
- package/dist/host/web/auth.d.ts +38 -0
- package/dist/host/web/auth.js +96 -0
- package/dist/host/web/backend.d.ts +14 -0
- package/dist/host/web/backend.js +1 -0
- package/dist/host/web/bridge.d.ts +27 -0
- package/dist/host/web/bridge.js +144 -0
- package/dist/host/web/browser.d.ts +1 -0
- package/dist/host/web/browser.js +10 -0
- package/dist/host/web/control.d.ts +17 -0
- package/dist/host/web/control.js +67 -0
- package/dist/host/web/index.d.ts +9 -0
- package/dist/host/web/index.js +8 -0
- package/dist/host/web/runner.d.ts +14 -0
- package/dist/host/web/runner.js +45 -0
- package/dist/host/web/server.d.ts +40 -0
- package/dist/host/web/server.js +218 -0
- package/dist/host/web/state.d.ts +20 -0
- package/dist/host/web/state.js +41 -0
- package/dist/host/web/static-files.d.ts +13 -0
- package/dist/host/web/static-files.js +57 -0
- package/dist/runtime/agent.js +27614 -0
- package/dist/runtime/daemon.js +1012 -618
- package/dist/runtime/db.js +236 -106
- package/dist/runtime/main.js +1093 -250
- package/dist/runtime/netproxy.js +102 -3
- package/dist/runtime/view.js +102 -3
- package/dist/selftest/accounts.test.js +40 -0
- package/dist/selftest/agent-paths.test.d.ts +2 -0
- package/dist/selftest/agent-paths.test.js +115 -0
- package/dist/selftest/channel.test.js +5 -0
- package/dist/selftest/cli.test.js +34 -4
- package/dist/selftest/credentials.test.d.ts +2 -0
- package/dist/selftest/credentials.test.js +198 -0
- package/dist/selftest/generate.test.js +1 -1
- package/dist/selftest/health.test.d.ts +2 -0
- package/dist/selftest/health.test.js +470 -0
- package/dist/selftest/host-sim.test.js +2 -0
- package/dist/selftest/index.js +19 -0
- package/dist/selftest/layout.test.js +2 -0
- package/dist/selftest/menu-screens.d.ts +7 -0
- package/dist/selftest/menu-screens.js +65 -16
- package/dist/selftest/menu.test.js +574 -21
- package/dist/selftest/migrate.test.js +1 -1
- package/dist/selftest/personalization.test.js +3 -1
- package/dist/selftest/projects.test.js +39 -1
- package/dist/selftest/shared-use.test.js +64 -2
- package/dist/selftest/sharing.test.js +50 -1
- package/dist/selftest/storage.test.d.ts +2 -0
- package/dist/selftest/storage.test.js +363 -0
- package/dist/selftest/support/fixtures.d.ts +14 -0
- package/dist/selftest/support/releases.js +1 -1
- package/dist/selftest/toolchains.test.js +21 -0
- package/dist/selftest/update-service.test.js +87 -3
- package/dist/selftest/vpn.test.d.ts +2 -0
- package/dist/selftest/vpn.test.js +279 -0
- package/dist/selftest/web.test.d.ts +2 -0
- package/dist/selftest/web.test.js +304 -0
- package/dist/shared/apps/catalogue.js +31 -0
- package/dist/shared/channel/index.d.ts +1 -0
- package/dist/shared/channel/index.js +1 -0
- package/dist/shared/channel/run-dir.d.ts +6 -1
- package/dist/shared/channel/run-dir.js +12 -1
- package/dist/shared/channel/schema.d.ts +19 -0
- package/dist/shared/channel/schema.js +11 -0
- package/dist/shared/channel/secrets.d.ts +28 -0
- package/dist/shared/channel/secrets.js +44 -0
- package/dist/shared/vpn/download.d.ts +13 -0
- package/dist/shared/vpn/download.js +14 -0
- package/dist/shared/vpn/kill-switch.d.ts +18 -0
- package/dist/shared/vpn/kill-switch.js +81 -0
- package/dist/shared/vpn/ovpn.d.ts +23 -0
- package/dist/shared/vpn/ovpn.js +244 -0
- package/dist/shared/web/index.d.ts +1 -0
- package/dist/shared/web/index.js +1 -0
- package/dist/shared/web/protocol.d.ts +61 -0
- package/dist/shared/web/protocol.js +35 -0
- package/dist/sync/sync-cycle.js +5 -1
- package/dist/sync/sync-state.d.ts +1 -0
- package/dist/sync/sync-state.js +1 -0
- package/dist/sync/watcher.js +10 -0
- package/dist/web/index.html +13 -0
- package/dist/web/main-CXESL347.js +45 -0
- package/dist/web/main-VLR7DVQ4.css +1 -0
- package/native/csharp/FolderSecurity.cs +29 -0
- package/native/scripts/protect-data.ps1 +29 -0
- package/native/scripts/read-folder-sddl.ps1 +10 -0
- package/native/scripts/set-folder-access.ps1 +49 -7
- package/node_modules/ws/LICENSE +20 -0
- package/node_modules/ws/README.md +548 -0
- package/node_modules/ws/browser.js +8 -0
- package/node_modules/ws/index.js +22 -0
- package/node_modules/ws/lib/buffer-util.js +131 -0
- package/node_modules/ws/lib/constants.js +19 -0
- package/node_modules/ws/lib/event-target.js +292 -0
- package/node_modules/ws/lib/extension.js +203 -0
- package/node_modules/ws/lib/limiter.js +55 -0
- package/node_modules/ws/lib/permessage-deflate.js +530 -0
- package/node_modules/ws/lib/receiver.js +743 -0
- package/node_modules/ws/lib/sender.js +607 -0
- package/node_modules/ws/lib/stream.js +161 -0
- package/node_modules/ws/lib/subprotocol.js +62 -0
- package/node_modules/ws/lib/validation.js +152 -0
- package/node_modules/ws/lib/websocket-server.js +562 -0
- package/node_modules/ws/lib/websocket.js +1421 -0
- package/node_modules/ws/package.json +74 -0
- package/node_modules/ws/wrapper.mjs +21 -0
- package/package.json +15 -5
- package/sandbox/csharp/EnvBroadcast.cs +33 -0
- package/sandbox/csharp/PathSync.cs +90 -0
- package/sandbox/scripts/install-shell-path.ps1 +73 -0
- package/sandbox/scripts/set-machine-environment.ps1 +37 -4
- package/schemas/config.schema.json +79 -4
- package/schemas/sandbox-config.schema.json +14 -1
- package/dist/cli/commands/repair/checks.d.ts +0 -2
- package/dist/cli/commands/repair/checks.js +0 -246
- package/dist/cli/menu/pages/start-page.d.ts +0 -43
- package/dist/cli/menu/pages/start-page.js +0 -192
- package/dist/cli/tui/tab-bar.d.ts +0 -9
- package/dist/cli/tui/tab-bar.js +0 -33
package/dist/cli/manifest.js
CHANGED
|
@@ -26,6 +26,13 @@ export const OptionSpecSchema = z.strictObject({
|
|
|
26
26
|
when: z.string().optional(),
|
|
27
27
|
/** Never offered in the menu (dangerous shortcuts such as --yes); typing it on the command line still works. */
|
|
28
28
|
noMenu: z.boolean().optional(),
|
|
29
|
+
/** Heading for this option in the command's --help (launch: Session, Folder ...). */
|
|
30
|
+
group: z.string().optional(),
|
|
31
|
+
/** The name shown in --help; `flag` stays accepted as a hidden alias (--agent shown, --harness still works). */
|
|
32
|
+
shownAs: z
|
|
33
|
+
.string()
|
|
34
|
+
.regex(/^--[a-z][a-z0-9-]*$/)
|
|
35
|
+
.optional(),
|
|
29
36
|
});
|
|
30
37
|
export const ArgSpecSchema = z.strictObject({
|
|
31
38
|
name: z.string(),
|
|
@@ -33,6 +40,8 @@ export const ArgSpecSchema = z.strictObject({
|
|
|
33
40
|
required: z.boolean(),
|
|
34
41
|
variadic: z.boolean().optional(),
|
|
35
42
|
choices: ChoicesSchema.optional(),
|
|
43
|
+
/** Spellings accepted besides `choices` but not listed (old names). */
|
|
44
|
+
aliases: z.array(z.string()).optional(),
|
|
36
45
|
/** Only asked in the menu when the command's first argument has this value, or one of these (data clean: targets). */
|
|
37
46
|
when: z.union([z.string(), z.array(z.string())]).optional(),
|
|
38
47
|
});
|
|
@@ -40,7 +49,7 @@ export const ArgSpecSchema = z.strictObject({
|
|
|
40
49
|
export function askedWhen(when, first) {
|
|
41
50
|
return when === undefined || (Array.isArray(when) ? when.includes(first) : when === first);
|
|
42
51
|
}
|
|
43
|
-
export const GroupSchema = z.enum(['Agents', '
|
|
52
|
+
export const GroupSchema = z.enum(['Agents', 'Sessions', 'Projects & accounts', 'Data', 'Web', 'Health', 'Advanced']);
|
|
44
53
|
export const CommandSpecSchema = z.strictObject({
|
|
45
54
|
name: z.string(),
|
|
46
55
|
summary: z.string(),
|
|
@@ -53,6 +62,8 @@ export const CommandSpecSchema = z.strictObject({
|
|
|
53
62
|
/** Takes over the terminal or ends the session: the menu does not come back afterwards. */
|
|
54
63
|
interactive: z.boolean().optional(),
|
|
55
64
|
hidden: z.boolean().optional(),
|
|
65
|
+
/** Command lines shown in an Examples block at the end of the command's --help. */
|
|
66
|
+
examples: z.array(z.string()).optional(),
|
|
56
67
|
});
|
|
57
68
|
function bool(flag, description, extra = {}) {
|
|
58
69
|
return {
|
|
@@ -91,16 +102,25 @@ const LABELS = {
|
|
|
91
102
|
function labelled(options) {
|
|
92
103
|
return options.map((o) => (LABELS[o.flag] ? { ...o, label: LABELS[o.flag] } : o));
|
|
93
104
|
}
|
|
105
|
+
const SESSION = 'Session';
|
|
106
|
+
const FOLDER = 'Folder';
|
|
107
|
+
const VERSIONS = 'Versions & services';
|
|
108
|
+
const TRUST = 'Trust';
|
|
94
109
|
const SANDBOX_OPTIONS = labelled([
|
|
95
|
-
bool('--terminal', "attach this terminal (reuses this folder's session if nobody is watching it)", {
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
110
|
+
bool('--terminal', "attach this terminal (reuses this folder's session if nobody is watching it)", {
|
|
111
|
+
short: '-t',
|
|
112
|
+
group: SESSION,
|
|
113
|
+
}),
|
|
114
|
+
bool('--headless', 'hide the sandbox window (sandbox show brings it back)', { group: SESSION }),
|
|
115
|
+
bool('--new', 'always start a new session, even if this folder has an unattached one', { group: SESSION }),
|
|
116
|
+
text('--workspace', 'dir', 'use this folder instead of the current one', { group: FOLDER }),
|
|
117
|
+
text('--node', 'version', "Node version (default: your project's .nvmrc or this PC's version)", {
|
|
100
118
|
advanced: true,
|
|
119
|
+
group: VERSIONS,
|
|
101
120
|
}),
|
|
102
|
-
text('--python', 'version',
|
|
121
|
+
text('--python', 'version', "Python 3 version (default: your project's .python-version or your settings)", {
|
|
103
122
|
advanced: true,
|
|
123
|
+
group: VERSIONS,
|
|
104
124
|
}),
|
|
105
125
|
{
|
|
106
126
|
flag: '--database',
|
|
@@ -109,6 +129,7 @@ const SANDBOX_OPTIONS = labelled([
|
|
|
109
129
|
description: 'also start this database (postgres, mysql, mongodb, redis, dynamodb; repeatable)',
|
|
110
130
|
choices: ['postgres', 'mysql', 'mongodb', 'redis', 'dynamodb'],
|
|
111
131
|
advanced: true,
|
|
132
|
+
group: VERSIONS,
|
|
112
133
|
},
|
|
113
134
|
{
|
|
114
135
|
flag: '--script',
|
|
@@ -116,24 +137,26 @@ const SANDBOX_OPTIONS = labelled([
|
|
|
116
137
|
value: 'file',
|
|
117
138
|
description: 'run this .ps1/.mjs/.cmd inside the sandbox first (repeatable)',
|
|
118
139
|
advanced: true,
|
|
140
|
+
group: VERSIONS,
|
|
119
141
|
},
|
|
120
|
-
bool('--window', 'show the sandbox window even if
|
|
121
|
-
bool('--trust-config', "approve the folder's .sandbox-config.json without asking", { advanced: true }),
|
|
122
|
-
bool('--no-local-config', "ignore the folder's .sandbox-config.json", { advanced: true }),
|
|
123
|
-
bool('--yes', '
|
|
142
|
+
bool('--window', 'show the sandbox window even if your settings say headless', { advanced: true, group: SESSION }),
|
|
143
|
+
bool('--trust-config', "approve the folder's .sandbox-config.json without asking", { advanced: true, group: TRUST }),
|
|
144
|
+
bool('--no-local-config', "ignore the folder's .sandbox-config.json", { advanced: true, group: TRUST }),
|
|
145
|
+
bool('--yes', 'restart the sandbox without asking if this folder needs it', { noMenu: true, group: TRUST }),
|
|
124
146
|
]);
|
|
125
147
|
const AGENT_OPTIONS = labelled([
|
|
126
|
-
text('--harness', 'name', 'agent to run', { choices: 'harnesses' }),
|
|
148
|
+
text('--harness', 'name', 'agent to run', { choices: 'harnesses', shownAs: '--agent', group: SESSION }),
|
|
127
149
|
{
|
|
128
150
|
flag: '--session',
|
|
129
151
|
type: 'list',
|
|
130
152
|
value: 'agent@folder',
|
|
131
|
-
description: 'start several sessions at once
|
|
153
|
+
description: 'start several sessions at once (repeatable; see the examples below; -t attaches the first)',
|
|
132
154
|
noMenu: true,
|
|
155
|
+
group: SESSION,
|
|
133
156
|
},
|
|
134
|
-
text('--account', 'name', 'Claude account for this sandbox', { choices: 'accounts' }),
|
|
157
|
+
text('--account', 'name', 'Claude account for this sandbox', { choices: 'accounts', group: SESSION }),
|
|
135
158
|
...SANDBOX_OPTIONS,
|
|
136
|
-
bool('--no-agent', 'set up the sandbox but do not start an agent', { advanced: true }),
|
|
159
|
+
bool('--no-agent', 'set up the sandbox but do not start an agent', { advanced: true, group: SESSION }),
|
|
137
160
|
]);
|
|
138
161
|
const json = true;
|
|
139
162
|
const COMMAND_LIST = [
|
|
@@ -145,11 +168,17 @@ const COMMAND_LIST = [
|
|
|
145
168
|
options: AGENT_OPTIONS,
|
|
146
169
|
passthrough: 'agent',
|
|
147
170
|
interactive: true,
|
|
171
|
+
examples: [
|
|
172
|
+
'sandbox claude -t start Claude here and attach this terminal',
|
|
173
|
+
'sandbox launch --agent codex start Codex in the current folder',
|
|
174
|
+
'sandbox launch --session claude@C:\\code\\api --session "codex@C:\\code\\web|--model o3"',
|
|
175
|
+
" two sessions at once (after | = that agent's own arguments)",
|
|
176
|
+
],
|
|
148
177
|
},
|
|
149
178
|
{
|
|
150
179
|
name: 'start',
|
|
151
180
|
summary: 'start a sandbox with no agent (tools and databases only)',
|
|
152
|
-
group: '
|
|
181
|
+
group: 'Agents',
|
|
153
182
|
args: [],
|
|
154
183
|
options: SANDBOX_OPTIONS.filter((o) => o.flag !== '--new'),
|
|
155
184
|
interactive: true,
|
|
@@ -157,7 +186,7 @@ const COMMAND_LIST = [
|
|
|
157
186
|
{
|
|
158
187
|
name: 'generate',
|
|
159
188
|
summary: 'show what a start would do, without starting anything',
|
|
160
|
-
group: '
|
|
189
|
+
group: 'Advanced',
|
|
161
190
|
args: [],
|
|
162
191
|
options: AGENT_OPTIONS,
|
|
163
192
|
passthrough: 'agent',
|
|
@@ -173,7 +202,7 @@ const COMMAND_LIST = [
|
|
|
173
202
|
{
|
|
174
203
|
name: 'resume',
|
|
175
204
|
summary: 'reopen the sessions from the last sandbox',
|
|
176
|
-
group: '
|
|
205
|
+
group: 'Agents',
|
|
177
206
|
args: [],
|
|
178
207
|
options: [
|
|
179
208
|
bool('--auto', 'used by the background sync after a crash: no questions', { noMenu: true, advanced: true }),
|
|
@@ -184,14 +213,14 @@ const COMMAND_LIST = [
|
|
|
184
213
|
summary: 'list agent sessions and who is attached',
|
|
185
214
|
group: 'Sessions',
|
|
186
215
|
args: [],
|
|
187
|
-
options: [],
|
|
216
|
+
options: [bool('--wide', "also show each session's folder", { noMenu: true })],
|
|
188
217
|
json,
|
|
189
218
|
},
|
|
190
|
-
{ name: 'status', summary: 'show what the sandbox is doing', group: '
|
|
219
|
+
{ name: 'status', summary: 'show what the sandbox is doing', group: 'Sessions', args: [], options: [], json },
|
|
191
220
|
{
|
|
192
221
|
name: 'db',
|
|
193
222
|
summary: 'list, start or stop databases in the running sandbox',
|
|
194
|
-
group: '
|
|
223
|
+
group: 'Sessions',
|
|
195
224
|
args: [
|
|
196
225
|
{ name: 'action', description: 'list, start or stop', required: false, choices: ['list', 'start', 'stop'] },
|
|
197
226
|
{
|
|
@@ -206,7 +235,11 @@ const COMMAND_LIST = [
|
|
|
206
235
|
{
|
|
207
236
|
name: 'exec',
|
|
208
237
|
summary: 'run a command inside the sandbox and print its output',
|
|
209
|
-
group: '
|
|
238
|
+
group: 'Sessions',
|
|
239
|
+
examples: [
|
|
240
|
+
'sandbox exec -- npm test run a command in the running sandbox',
|
|
241
|
+
'sandbox exec --json -- node -v the result as JSON',
|
|
242
|
+
],
|
|
210
243
|
args: [{ name: 'command', description: 'command and its arguments', required: true, variadic: true }],
|
|
211
244
|
options: [
|
|
212
245
|
{
|
|
@@ -224,25 +257,30 @@ const COMMAND_LIST = [
|
|
|
224
257
|
{
|
|
225
258
|
name: 'restart',
|
|
226
259
|
summary: "restart this project's running agents in place; they resume their conversation",
|
|
227
|
-
group: '
|
|
260
|
+
group: 'Agents',
|
|
228
261
|
args: [],
|
|
229
262
|
options: [
|
|
230
|
-
text('--harness', 'name', 'only this agent', { choices: 'harnesses' }),
|
|
263
|
+
text('--harness', 'name', 'only this agent', { choices: 'harnesses', shownAs: '--agent' }),
|
|
231
264
|
bool('--all', "every project's sessions, not only this folder's"),
|
|
232
265
|
],
|
|
233
266
|
},
|
|
234
267
|
{
|
|
235
268
|
name: 'stop',
|
|
236
269
|
summary: "shut the sandbox down (every project's sessions end)",
|
|
237
|
-
group: '
|
|
270
|
+
group: 'Agents',
|
|
238
271
|
args: [],
|
|
239
|
-
options: [bool('--yes', "do not ask when other projects' sessions would end", { noMenu: true })],
|
|
272
|
+
options: [bool('--yes', "do not ask when other projects' sessions would end", { short: '-y', noMenu: true })],
|
|
240
273
|
},
|
|
241
274
|
{
|
|
242
275
|
name: 'projects',
|
|
243
276
|
summary: 'the projects a sandbox can open without a restart: list, choose, roots, all/exclude',
|
|
244
|
-
group: '
|
|
277
|
+
group: 'Projects & accounts',
|
|
245
278
|
json,
|
|
279
|
+
examples: [
|
|
280
|
+
'sandbox projects list your projects',
|
|
281
|
+
'sandbox projects add . remember this folder',
|
|
282
|
+
'sandbox projects roots add C:\\code share every project in C:\\code',
|
|
283
|
+
],
|
|
246
284
|
args: [
|
|
247
285
|
{
|
|
248
286
|
name: 'action',
|
|
@@ -258,14 +296,18 @@ const COMMAND_LIST = [
|
|
|
258
296
|
},
|
|
259
297
|
{ name: 'folder', description: '(roots add/remove) the folder', required: false, when: 'roots' },
|
|
260
298
|
],
|
|
261
|
-
options: [],
|
|
299
|
+
options: [bool('--yes', 'do not ask before removing', { short: '-y', when: 'remove', noMenu: true })],
|
|
262
300
|
},
|
|
263
|
-
{ name: 'show', summary: 'show the sandbox window', group: '
|
|
264
|
-
{ name: 'hide', summary: 'hide the sandbox window (it keeps running)', group: '
|
|
301
|
+
{ name: 'show', summary: 'show the sandbox window', group: 'Sessions', args: [], options: [] },
|
|
302
|
+
{ name: 'hide', summary: 'hide the sandbox window (it keeps running)', group: 'Sessions', args: [], options: [] },
|
|
265
303
|
{
|
|
266
304
|
name: 'account',
|
|
267
305
|
summary: 'Claude logins: list, save, use, set the default, remove',
|
|
268
|
-
group: '
|
|
306
|
+
group: 'Projects & accounts',
|
|
307
|
+
examples: [
|
|
308
|
+
'sandbox account save work save the login you signed in with inside the sandbox',
|
|
309
|
+
'sandbox account use work the sandbox uses it (running sessions restart)',
|
|
310
|
+
],
|
|
269
311
|
args: [
|
|
270
312
|
{
|
|
271
313
|
name: 'action',
|
|
@@ -283,6 +325,7 @@ const COMMAND_LIST = [
|
|
|
283
325
|
}),
|
|
284
326
|
bool('--from-host', "(save) save this PC's login instead of the sandbox's", { when: 'save' }),
|
|
285
327
|
bool('--no-restart', '(use) do not restart running sessions', { when: 'use' }),
|
|
328
|
+
bool('--yes', '(remove) do not ask first', { short: '-y', when: 'remove', noMenu: true }),
|
|
286
329
|
],
|
|
287
330
|
json,
|
|
288
331
|
},
|
|
@@ -291,7 +334,13 @@ const COMMAND_LIST = [
|
|
|
291
334
|
summary: 'show what is kept between sandboxes (tools, databases, logins, logs), or delete some of it',
|
|
292
335
|
group: 'Data',
|
|
293
336
|
args: [
|
|
294
|
-
{
|
|
337
|
+
{
|
|
338
|
+
name: 'action',
|
|
339
|
+
description: 'show or clean',
|
|
340
|
+
required: false,
|
|
341
|
+
choices: ['show', 'clean'],
|
|
342
|
+
aliases: ['info', 'list', 'remove'],
|
|
343
|
+
},
|
|
295
344
|
{
|
|
296
345
|
name: 'targets',
|
|
297
346
|
description: 'what to clean, e.g. tools/go databases logs',
|
|
@@ -300,7 +349,29 @@ const COMMAND_LIST = [
|
|
|
300
349
|
when: 'clean',
|
|
301
350
|
},
|
|
302
351
|
],
|
|
303
|
-
options: [bool('--yes', 'do not ask before deleting', { noMenu: true })],
|
|
352
|
+
options: [bool('--yes', 'do not ask before deleting', { short: '-y', noMenu: true })],
|
|
353
|
+
json,
|
|
354
|
+
examples: [
|
|
355
|
+
'sandbox data clean pick what to delete from a list',
|
|
356
|
+
'sandbox data clean logs tools/go delete these',
|
|
357
|
+
],
|
|
358
|
+
},
|
|
359
|
+
{
|
|
360
|
+
name: 'storage',
|
|
361
|
+
summary: 'where your saved data lives: show it, move it to another folder, or switch folders',
|
|
362
|
+
group: 'Data',
|
|
363
|
+
examples: [
|
|
364
|
+
'sandbox storage where the data is',
|
|
365
|
+
'sandbox storage move D:\\sandbox-data move it (asks first)',
|
|
366
|
+
],
|
|
367
|
+
args: [
|
|
368
|
+
{ name: 'action', description: 'show, move or use', required: false, choices: ['show', 'move', 'use'] },
|
|
369
|
+
{ name: 'folder', description: 'the folder to move to, or to use', required: false, when: ['move', 'use'] },
|
|
370
|
+
],
|
|
371
|
+
options: [
|
|
372
|
+
bool('--yes', 'do not ask before moving or switching', { short: '-y', noMenu: true }),
|
|
373
|
+
bool('--keep-old', 'copy instead of moving: the old folder stays (needs room for both)', { when: 'move' }),
|
|
374
|
+
],
|
|
304
375
|
json,
|
|
305
376
|
},
|
|
306
377
|
{
|
|
@@ -316,12 +387,13 @@ const COMMAND_LIST = [
|
|
|
316
387
|
description: 'launch folders older than this many days',
|
|
317
388
|
default: 7,
|
|
318
389
|
},
|
|
390
|
+
bool('--yes', 'do not ask before deleting', { short: '-y', noMenu: true }),
|
|
319
391
|
],
|
|
320
392
|
},
|
|
321
393
|
{ name: 'sync', summary: 'copy conversation history back to this PC now', group: 'Data', args: [], options: [] },
|
|
322
394
|
{
|
|
323
395
|
name: 'audit',
|
|
324
|
-
summary: 'what happened in your sandboxes: programs started, files changed, sessions, repo guard (audit.enabled)',
|
|
396
|
+
summary: 'what happened in your sandboxes: programs started, files changed, sessions, repo guard (turn it on: sandbox config set audit.enabled true)',
|
|
325
397
|
group: 'Health',
|
|
326
398
|
json,
|
|
327
399
|
args: [],
|
|
@@ -349,10 +421,14 @@ const COMMAND_LIST = [
|
|
|
349
421
|
},
|
|
350
422
|
{
|
|
351
423
|
name: 'doctor',
|
|
352
|
-
summary: 'check this PC and
|
|
424
|
+
summary: 'check this PC, the install, your settings and the sandbox, and offer to fix what it finds',
|
|
353
425
|
group: 'Health',
|
|
354
426
|
args: [],
|
|
355
|
-
options: [
|
|
427
|
+
options: [
|
|
428
|
+
text('--harness', 'name', 'agent to check', { choices: 'harnesses', shownAs: '--agent' }),
|
|
429
|
+
bool('--fix', 'fix what can be fixed without asking', { noMenu: true }),
|
|
430
|
+
],
|
|
431
|
+
json: true,
|
|
356
432
|
},
|
|
357
433
|
{
|
|
358
434
|
name: 'migrate',
|
|
@@ -364,6 +440,7 @@ const COMMAND_LIST = [
|
|
|
364
440
|
text('--restore', 'backup', 'put back the files saved before an update (a folder under <storage>\\backups)', {
|
|
365
441
|
advanced: true,
|
|
366
442
|
}),
|
|
443
|
+
bool('--yes', '(--restore) do not ask first', { short: '-y', noMenu: true }),
|
|
367
444
|
],
|
|
368
445
|
},
|
|
369
446
|
{
|
|
@@ -374,6 +451,7 @@ const COMMAND_LIST = [
|
|
|
374
451
|
options: [
|
|
375
452
|
bool('--check', 'only look whether a newer version exists'),
|
|
376
453
|
bool('--rollback', 'go back to the version before the last update'),
|
|
454
|
+
bool('--yes', '(--rollback) do not ask first', { short: '-y', noMenu: true }),
|
|
377
455
|
text('--auto', 'on|off', 'install new versions by themselves (for everyone on this PC: needs an admin terminal)', {
|
|
378
456
|
choices: ['on', 'off'],
|
|
379
457
|
}),
|
|
@@ -386,15 +464,17 @@ const COMMAND_LIST = [
|
|
|
386
464
|
},
|
|
387
465
|
{
|
|
388
466
|
name: 'repair',
|
|
389
|
-
summary: 'find and fix
|
|
467
|
+
summary: 'find and fix problems (install, data folder, settings, stale state, half-installed tools)',
|
|
390
468
|
group: 'Health',
|
|
391
469
|
args: [],
|
|
392
|
-
options: [],
|
|
470
|
+
options: [bool('--yes', 'do not ask before fixing', { short: '-y', noMenu: true })],
|
|
471
|
+
json: true,
|
|
393
472
|
},
|
|
394
473
|
{
|
|
395
474
|
name: 'self-test',
|
|
396
475
|
summary: 'run the built-in tests',
|
|
397
476
|
group: 'Health',
|
|
477
|
+
hidden: true,
|
|
398
478
|
args: [
|
|
399
479
|
{
|
|
400
480
|
name: 'suite',
|
|
@@ -408,32 +488,58 @@ const COMMAND_LIST = [
|
|
|
408
488
|
{
|
|
409
489
|
name: 'config',
|
|
410
490
|
summary: "show or create your settings file, or check a project's .sandbox-config.json",
|
|
411
|
-
group: '
|
|
491
|
+
group: 'Health',
|
|
412
492
|
args: [
|
|
413
493
|
{
|
|
414
494
|
name: 'action',
|
|
415
495
|
description: 'what to do',
|
|
416
496
|
required: false,
|
|
417
|
-
choices: ['show', 'path', 'init', 'schema', 'check'],
|
|
497
|
+
choices: ['show', 'path', 'init', 'schema', 'check', 'get', 'set'],
|
|
498
|
+
aliases: ['summary'],
|
|
418
499
|
},
|
|
500
|
+
{
|
|
501
|
+
name: 'key',
|
|
502
|
+
description: '(get, set) the setting, e.g. sandbox.memoryMb',
|
|
503
|
+
required: false,
|
|
504
|
+
when: ['get', 'set'],
|
|
505
|
+
},
|
|
506
|
+
{ name: 'value', description: '(set) the new value', required: false, when: 'set' },
|
|
419
507
|
],
|
|
420
508
|
options: [text('--workspace', 'dir', '(check) the project folder; default: the current one')],
|
|
509
|
+
examples: ['sandbox config set sandbox.memoryMb 8192', 'sandbox config get sandbox.memoryMb'],
|
|
421
510
|
},
|
|
422
511
|
{
|
|
423
512
|
name: 'agent-commands',
|
|
424
513
|
summary: '(Beta) make claude, codex ... on this PC start in a hidden sandbox and attach',
|
|
425
|
-
group: '
|
|
514
|
+
group: 'Advanced',
|
|
426
515
|
args: [{ name: 'action', description: 'on, off or status', required: false, choices: ['status', 'on', 'off'] }],
|
|
427
516
|
options: [],
|
|
428
517
|
},
|
|
518
|
+
{
|
|
519
|
+
name: 'vpn',
|
|
520
|
+
summary: 'the VPN for the sandbox: save your login, see whether it is on (NordVPN first)',
|
|
521
|
+
group: 'Advanced',
|
|
522
|
+
args: [
|
|
523
|
+
{
|
|
524
|
+
name: 'action',
|
|
525
|
+
description: 'status, login or logout',
|
|
526
|
+
required: false,
|
|
527
|
+
choices: ['status', 'login', 'logout'],
|
|
528
|
+
},
|
|
529
|
+
],
|
|
530
|
+
options: [],
|
|
531
|
+
json: true,
|
|
532
|
+
examples: ['sandbox vpn login', 'sandbox vpn status'],
|
|
533
|
+
},
|
|
429
534
|
{
|
|
430
535
|
name: 'host-claude',
|
|
431
|
-
summary: 'run Claude on this PC, NOT sandboxed, with its own profile',
|
|
536
|
+
summary: 'run Claude on this PC, NOT sandboxed, with its own profile (same as: sandbox host claude)',
|
|
432
537
|
group: 'Agents',
|
|
433
538
|
args: [],
|
|
434
539
|
options: [bool('--personal', 'use your normal Claude profile')],
|
|
435
540
|
passthrough: 'agent',
|
|
436
541
|
interactive: true,
|
|
542
|
+
hidden: true,
|
|
437
543
|
},
|
|
438
544
|
{
|
|
439
545
|
name: 'host',
|
|
@@ -447,13 +553,37 @@ const COMMAND_LIST = [
|
|
|
447
553
|
{
|
|
448
554
|
name: 'menu',
|
|
449
555
|
summary: 'the interactive menu (what `sandbox` opens with no arguments)',
|
|
450
|
-
group: '
|
|
556
|
+
group: 'Advanced',
|
|
451
557
|
args: [],
|
|
452
558
|
options: [],
|
|
453
559
|
hidden: true,
|
|
454
560
|
interactive: true,
|
|
455
561
|
},
|
|
562
|
+
{
|
|
563
|
+
name: 'web',
|
|
564
|
+
summary: '(beta) your sandbox sessions in a browser on this PC: start, stop, status or open',
|
|
565
|
+
group: 'Web',
|
|
566
|
+
examples: ['sandbox web open start the web UI and open it in your browser'],
|
|
567
|
+
args: [
|
|
568
|
+
{
|
|
569
|
+
name: 'action',
|
|
570
|
+
description: 'start the server, stop it, show whether it runs, or open it in your browser',
|
|
571
|
+
required: false,
|
|
572
|
+
choices: ['start', 'stop', 'status', 'open'],
|
|
573
|
+
},
|
|
574
|
+
],
|
|
575
|
+
options: [],
|
|
576
|
+
json,
|
|
577
|
+
},
|
|
456
578
|
{ name: '_watch', summary: 'background history sync', group: 'Data', args: [], options: [], hidden: true },
|
|
579
|
+
{
|
|
580
|
+
name: '_web',
|
|
581
|
+
summary: 'the web UI server (started by sandbox web start)',
|
|
582
|
+
group: 'Web',
|
|
583
|
+
args: [],
|
|
584
|
+
options: [],
|
|
585
|
+
hidden: true,
|
|
586
|
+
},
|
|
457
587
|
];
|
|
458
588
|
export const COMMANDS = z.array(CommandSpecSchema).parse(COMMAND_LIST);
|
|
459
589
|
export function commandSpec(name) {
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
import type { Harness } from '../../core/types.js';
|
|
2
|
+
import type { App } from '../tui/index.js';
|
|
3
|
+
import type { ConfigFile } from './settings/config-file.js';
|
|
4
|
+
import type { Draft } from './settings/draft.js';
|
|
5
|
+
/** How a new agent gets into the sandbox. */
|
|
6
|
+
export type AgentSource = 'npm' | 'uv' | 'host';
|
|
7
|
+
/** Nothing wrong with the name (true), or what is wrong. Pure. */
|
|
8
|
+
export declare function agentNameProblem(name: string, taken: readonly string[]): true | string;
|
|
9
|
+
/** The command a package usually provides: "@scope/my-agent@latest" gives "my-agent". Pure. */
|
|
10
|
+
export declare function commandFromPackage(pkg: string): string;
|
|
11
|
+
/** The config entry for a new agent. Pure. */
|
|
12
|
+
export declare function newAgent(source: AgentSource, what: string, command: string, hostDir?: string): Harness;
|
|
13
|
+
/** What `harnesses` should say with `name` taken out. Pure. */
|
|
14
|
+
export declare function withoutAgent(current: unknown, name: string): Record<string, unknown>;
|
|
15
|
+
/** Writes a setting to your config file now, or adds it to the unsaved changes when it has some already. */
|
|
16
|
+
export declare function writeOrStage(file: ConfigFile, draft: Draft, key: string[], value: unknown): {
|
|
17
|
+
saved: boolean;
|
|
18
|
+
};
|
|
19
|
+
/** What `harnesses` should say with `name` added to what is staged or in the file now. Pure. */
|
|
20
|
+
export declare function withAgent(current: unknown, name: string, harness: Harness): Record<string, unknown>;
|
|
21
|
+
/** Makes `name` the agent that starts by default (written now, or joined to unsaved changes to that setting). */
|
|
22
|
+
export declare function makeDefaultAgent(file: ConfigFile, draft: Draft, name: string): {
|
|
23
|
+
saved: boolean;
|
|
24
|
+
};
|
|
25
|
+
/** Takes an agent you added out of your settings (the built-in ones are not removable). */
|
|
26
|
+
export declare function removeAgent(file: ConfigFile, draft: Draft, name: string): {
|
|
27
|
+
saved: boolean;
|
|
28
|
+
};
|
|
29
|
+
export interface AddedAgent {
|
|
30
|
+
readonly name: string;
|
|
31
|
+
/** Written to your config file now (false: waiting for Ctrl+S with the other unsaved changes). */
|
|
32
|
+
readonly saved: boolean;
|
|
33
|
+
}
|
|
34
|
+
export declare class AddAgent {
|
|
35
|
+
private readonly app;
|
|
36
|
+
private readonly file;
|
|
37
|
+
private readonly draft;
|
|
38
|
+
/** Every agent that exists now (the new name must be different). */
|
|
39
|
+
private readonly taken;
|
|
40
|
+
constructor(app: App, file: ConfigFile, draft: Draft,
|
|
41
|
+
/** Every agent that exists now (the new name must be different). */
|
|
42
|
+
taken: readonly string[]);
|
|
43
|
+
/** Asks, then adds the agent. Undefined when you backed out. */
|
|
44
|
+
run(): Promise<AddedAgent | undefined>;
|
|
45
|
+
/** Validates and writes (or stages) the entry. */
|
|
46
|
+
private add;
|
|
47
|
+
}
|