windows-development-sandbox 1.20.0 → 1.23.1
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/config.example.json +8 -1
- package/dist/app/features/access/access.def.js +5 -2
- package/dist/app/features/access/access.run.js +7 -3
- package/dist/app/features/accounts/accounts.def.d.ts +29 -1
- package/dist/app/features/accounts/accounts.def.js +10 -4
- package/dist/app/features/accounts/accounts.run.d.ts +1 -0
- package/dist/app/features/accounts/accounts.run.js +7 -2
- package/dist/app/features/accounts/services.def.d.ts +4 -1
- package/dist/app/features/accounts/services.def.js +15 -14
- package/dist/app/features/accounts/services.run.d.ts +1 -0
- package/dist/app/features/accounts/services.run.js +41 -15
- package/dist/app/features/defs.d.ts +39 -2
- package/dist/app/features/engine/engine.run.js +1 -1
- package/dist/app/features/github/github.def.d.ts +44 -3
- package/dist/app/features/github/github.def.js +145 -63
- package/dist/app/features/github/github.run.d.ts +9 -2
- package/dist/app/features/github/github.run.js +43 -5
- package/dist/app/features/health/health.def.js +8 -2
- package/dist/app/features/logs/logs.def.js +0 -8
- package/dist/app/features/projects/projects.def.js +2 -2
- package/dist/app/features/projects/projects.run.js +5 -5
- package/dist/app/features/sandbox/sandbox.def.js +7 -3
- package/dist/app/features/sessions/sessions.def.d.ts +4 -4
- package/dist/app/features/sessions/sessions.def.js +0 -5
- package/dist/app/features/sessions/sessions.run.d.ts +1 -1
- package/dist/app/features/sessions/sessions.run.js +2 -2
- package/dist/app/features/settings/categories.def.js +2 -0
- package/dist/app/features/settings/settings-rows.js +1 -1
- package/dist/app/features/settings/settings.def.js +1 -1
- package/dist/app/features/settings/settings.run.js +3 -3
- package/dist/app/features/storage/storage.run.js +18 -9
- package/dist/app/features/updates/update-lines.js +2 -2
- package/dist/app/features/updates/updates.def.js +1 -1
- package/dist/app/features/updates/updates.run.js +1 -1
- package/dist/app/features/web/web.def.js +2 -2
- package/dist/app/features/web/web.run.js +12 -4
- package/dist/app/kernel/errors.d.ts +7 -0
- package/dist/app/kernel/errors.js +18 -3
- package/dist/app/kernel/rpc.d.ts +5 -0
- package/dist/app/kernel/view.d.ts +11 -1
- package/dist/bin/agent-sandbox.js +2 -2
- package/dist/bin/{chunk-DK4NTBUF.js → chunk-7YPEDAJD.js} +172 -48
- package/dist/bin/{chunk-2IMT7ZCT.js → chunk-QFSJX2KW.js} +1 -1
- package/dist/bin/{chunk-Z2P5OGKL.js → chunk-USTRSHIE.js} +2436 -1693
- package/dist/bin/claude-host.js +2 -2
- package/dist/bin/claude-sbx.js +2 -2
- package/dist/bin/codex-sbx.js +2 -2
- package/dist/bin/gemini-sbx.js +2 -2
- package/dist/bin/sandbox.js +2 -2
- package/dist/bin/sbx-hide.js +2 -2
- package/dist/bin/sbx-show.js +2 -2
- package/dist/cli/manifest.d.ts +2 -2
- package/dist/cli/manifest.js +2 -1
- package/dist/cli/menu/coverage-exempt.d.ts +17 -0
- package/dist/cli/menu/coverage-exempt.js +61 -0
- package/dist/cli/menu/io-menu.d.ts +2 -0
- package/dist/cli/menu/io-menu.js +50 -5
- package/dist/cli/menu/pages/accounts-page.js +1 -1
- package/dist/cli/menu/pages/agents-page.js +8 -2
- package/dist/cli/menu/pages/maintenance-page.d.ts +6 -0
- package/dist/cli/menu/pages/maintenance-page.js +9 -2
- package/dist/cli/menu/pages/sessions-page.d.ts +2 -0
- package/dist/cli/menu/pages/sessions-page.js +12 -4
- package/dist/cli/menu/pages/settings-page.js +12 -1
- package/dist/cli/menu/remote-menu.js +1 -1
- package/dist/cli/menu/shell.d.ts +5 -0
- package/dist/cli/menu/shell.js +13 -0
- package/dist/cli/report.js +2 -0
- package/dist/cli/tui/app.d.ts +5 -0
- package/dist/cli/tui/app.js +2 -0
- package/dist/core/config/defaults.js +3 -1
- package/dist/core/schema/accounts.d.ts +6 -0
- package/dist/core/schema/accounts.js +13 -11
- package/dist/core/schema/config.d.ts +20 -8
- package/dist/core/schema/config.js +4 -4
- package/dist/core/schema/github.js +1 -1
- package/dist/core/schema/profile.js +8 -4
- package/dist/core/schema/resume.js +1 -1
- package/dist/core/schema/sandbox.js +3 -3
- package/dist/core/schema/vpn.js +1 -1
- package/dist/core/schema/web.js +3 -3
- package/dist/core/types.d.ts +6 -0
- package/dist/core/util/errors.d.ts +11 -1
- package/dist/core/util/errors.js +7 -1
- package/dist/core/util/index.d.ts +1 -1
- package/dist/core/util/index.js +1 -1
- package/dist/guest/accounts/adapter.d.ts +2 -0
- package/dist/guest/accounts/adapters.js +4 -0
- package/dist/guest/accounts/apply.d.ts +6 -2
- package/dist/guest/accounts/kinds/cfx.d.ts +7 -0
- package/dist/guest/accounts/kinds/cfx.js +33 -3
- package/dist/guest/accounts/kinds/comet.d.ts +7 -0
- package/dist/guest/accounts/kinds/comet.js +50 -0
- package/dist/guest/accounts/kinds/perplexity.d.ts +2 -0
- package/dist/guest/accounts/kinds/perplexity.js +12 -0
- package/dist/guest/accounts/watch.d.ts +2 -0
- package/dist/guest/accounts/watch.js +12 -2
- package/dist/guest/agents/agent-installer.js +1 -1
- package/dist/guest/agents/profile-links.d.ts +2 -0
- package/dist/guest/agents/profile-links.js +18 -4
- package/dist/guest/apps/after-install.js +19 -0
- package/dist/guest/apps/app-installer.d.ts +11 -0
- package/dist/guest/apps/app-installer.js +69 -6
- package/dist/guest/apps/comet-unpack.d.ts +20 -0
- package/dist/guest/apps/comet-unpack.js +127 -0
- package/dist/guest/apps/index.d.ts +1 -1
- package/dist/guest/apps/index.js +1 -1
- package/dist/guest/apps/resolvers-agents-web.d.ts +2 -0
- package/dist/guest/apps/resolvers-agents-web.js +7 -0
- package/dist/guest/apps/resolvers.js +2 -0
- package/dist/guest/apps/shortcuts.d.ts +2 -0
- package/dist/guest/apps/shortcuts.js +1 -0
- package/dist/guest/apps/unpack.js +14 -4
- package/dist/guest/boot/boot.d.ts +45 -16
- package/dist/guest/boot/boot.js +316 -145
- package/dist/guest/boot/graph.d.ts +252 -0
- package/dist/guest/boot/graph.js +257 -0
- package/dist/guest/boot/guide-lines.d.ts +25 -0
- package/dist/guest/boot/guide-lines.js +41 -0
- package/dist/guest/boot/guide.d.ts +1 -4
- package/dist/guest/boot/guide.js +6 -8
- package/dist/guest/boot/runner.d.ts +77 -0
- package/dist/guest/boot/runner.js +215 -0
- package/dist/guest/browser/cdp.d.ts +71 -0
- package/dist/guest/browser/cdp.js +306 -0
- package/dist/guest/browser/comet.d.ts +28 -0
- package/dist/guest/browser/comet.js +155 -0
- package/dist/guest/daemon/project-provisioner.js +6 -1
- package/dist/guest/devtools/fivem.d.ts +1 -1
- package/dist/guest/devtools/fivem.js +243 -3
- package/dist/guest/entries/daemon.js +2 -0
- package/dist/guest/runtime/log.d.ts +12 -0
- package/dist/guest/runtime/log.js +29 -5
- package/dist/guest/runtime/pools.d.ts +24 -0
- package/dist/guest/runtime/pools.js +60 -0
- package/dist/guest/runtime/process.d.ts +4 -0
- package/dist/guest/runtime/process.js +38 -1
- package/dist/guest/runtime/status.d.ts +5 -1
- package/dist/guest/runtime/status.js +19 -0
- package/dist/guest/setup/addon-mcp.d.ts +1 -1
- package/dist/guest/setup/addon-mcp.js +52 -12
- package/dist/guest/setup/agent-addons.d.ts +3 -2
- package/dist/guest/setup/agent-addons.js +12 -3
- package/dist/guest/setup/environment.d.ts +1 -1
- package/dist/guest/setup/environment.js +25 -12
- package/dist/guest/setup/headroom.d.ts +8 -3
- package/dist/guest/setup/headroom.js +44 -15
- package/dist/guest/setup/path-plan.d.ts +28 -0
- package/dist/guest/setup/path-plan.js +69 -2
- package/dist/guest/setup/shell-path.d.ts +1 -1
- package/dist/guest/setup/shell-path.js +3 -3
- package/dist/guest/toolchains/fivem/artifacts.d.ts +48 -1
- package/dist/guest/toolchains/fivem/artifacts.js +97 -4
- package/dist/guest/toolchains/fivem/fivem.d.ts +32 -1
- package/dist/guest/toolchains/fivem/fivem.js +168 -3
- package/dist/guest/toolchains/fivem/scaffold.d.ts +35 -0
- package/dist/guest/toolchains/fivem/scaffold.js +105 -0
- package/dist/guest/toolchains/fivem/serve-plan.d.ts +34 -0
- package/dist/guest/toolchains/fivem/serve-plan.js +61 -0
- package/dist/guest/toolchains/languages/go.js +1 -1
- package/dist/guest/toolchains/languages/node.js +2 -1
- package/dist/guest/toolchains/languages/php.d.ts +2 -0
- package/dist/guest/toolchains/languages/php.js +13 -1
- package/dist/guest/toolchains/languages/python-tools.js +1 -1
- package/dist/guest/toolchains/languages/ruby.js +1 -1
- package/dist/guest/toolchains/native/binstall.js +1 -1
- package/dist/guest/toolchains/native/msvc/packages.js +10 -4
- package/dist/guest/toolchains/native/rust.d.ts +2 -0
- package/dist/guest/toolchains/native/rust.js +11 -4
- package/dist/guest/toolchains/native/unreal.d.ts +2 -0
- package/dist/guest/toolchains/native/unreal.js +16 -6
- package/dist/guest/toolchains/native/vcruntime.d.ts +2 -0
- package/dist/guest/toolchains/native/vcruntime.js +10 -2
- package/dist/guest/toolchains/native/visual-studio.d.ts +3 -0
- package/dist/guest/toolchains/native/visual-studio.js +44 -26
- package/dist/guest/toolchains/native/vs-request.d.ts +2 -0
- package/dist/guest/toolchains/native/vs-request.js +2 -0
- package/dist/guest/toolchains/plan.js +19 -8
- package/dist/guest/toolchains/scheduler.d.ts +2 -21
- package/dist/guest/toolchains/scheduler.js +7 -121
- package/dist/guest/toolchains/setup.d.ts +15 -2
- package/dist/guest/toolchains/setup.js +39 -20
- package/dist/guest/toolchains/split.d.ts +28 -0
- package/dist/guest/toolchains/split.js +60 -0
- package/dist/guest/toolchains/steam/client.js +2 -1
- package/dist/guest/toolchains/step-scheduler.d.ts +51 -0
- package/dist/guest/toolchains/step-scheduler.js +147 -0
- package/dist/guest/toolchains/step.d.ts +13 -0
- package/dist/guest/toolchains/tools/git.js +18 -0
- package/dist/guest/vpn/openvpn.js +3 -4
- package/dist/guest/vpn/wireguard.js +11 -4
- package/dist/host/accounts/deliver.js +7 -0
- package/dist/host/accounts/handoff.js +2 -6
- package/dist/host/accounts/index.d.ts +1 -1
- package/dist/host/accounts/index.js +1 -1
- package/dist/host/accounts/kinds/cfx.d.ts +1 -1
- package/dist/host/accounts/kinds/cfx.js +47 -4
- package/dist/host/accounts/kinds/comet.d.ts +2 -0
- package/dist/host/accounts/kinds/comet.js +6 -0
- package/dist/host/accounts/kinds/perplexity.d.ts +2 -0
- package/dist/host/accounts/kinds/perplexity.js +30 -0
- package/dist/host/accounts/leases.d.ts +7 -1
- package/dist/host/accounts/leases.js +13 -2
- package/dist/host/accounts/source.d.ts +7 -1
- package/dist/host/accounts/source.js +27 -0
- package/dist/host/accounts/sources.js +4 -0
- package/dist/host/github/deliver.d.ts +1 -1
- package/dist/host/github/deliver.js +20 -1
- package/dist/host/github/index.d.ts +2 -1
- package/dist/host/github/index.js +1 -0
- package/dist/host/github/token.d.ts +13 -1
- package/dist/host/github/token.js +19 -2
- package/dist/host/github/verify.d.ts +27 -0
- package/dist/host/github/verify.js +61 -0
- package/dist/host/launch/hints/fivem.d.ts +3 -1
- package/dist/host/launch/hints/fivem.js +68 -2
- package/dist/host/launch/session-file.js +4 -0
- package/dist/host/launch/toolchains.d.ts +2 -1
- package/dist/host/launch/toolchains.js +5 -3
- package/dist/host/profile/claude-login.d.ts +2 -2
- package/dist/host/profile/claude-login.js +4 -3
- package/dist/host/vpn/nordvpn.d.ts +2 -4
- package/dist/host/vpn/nordvpn.js +2 -24
- package/dist/runtime/agent.js +405 -90
- package/dist/runtime/daemon.js +3010 -1383
- package/dist/runtime/db.js +333 -90
- package/dist/runtime/main.js +4720 -1954
- package/dist/runtime/netproxy.js +286 -69
- package/dist/runtime/tool.js +2852 -1780
- package/dist/runtime/view.js +286 -69
- package/dist/selftest/accounts.test.js +1 -1
- package/dist/selftest/agent-paths.test.js +39 -1
- package/dist/selftest/agent-settings.test.js +6 -0
- package/dist/selftest/agents-web.test.d.ts +2 -0
- package/dist/selftest/agents-web.test.js +647 -0
- package/dist/selftest/app.test.js +5 -2
- package/dist/selftest/boot-runner.test.d.ts +2 -0
- package/dist/selftest/boot-runner.test.js +456 -0
- package/dist/selftest/channel.test.js +15 -0
- package/dist/selftest/fivem.test.js +249 -3
- package/dist/selftest/github.test.js +94 -9
- package/dist/selftest/guest-boot.test.js +3 -0
- package/dist/selftest/health.test.js +1 -1
- package/dist/selftest/index.js +8 -0
- package/dist/selftest/layout.test.js +5 -0
- package/dist/selftest/menu-coverage.test.d.ts +2 -0
- package/dist/selftest/menu-coverage.test.js +46 -0
- package/dist/selftest/menu-screens.js +37 -1
- package/dist/selftest/persisted-installs.test.js +6 -3
- package/dist/selftest/service-accounts.test.js +3 -2
- package/dist/selftest/support/engine-golden.js +27 -0
- package/dist/selftest/support/fixtures.d.ts +6 -0
- package/dist/selftest/support/web-preview.d.ts +34 -1
- package/dist/selftest/support/web-preview.js +21 -18
- package/dist/selftest/toolchains.test.js +23 -1
- package/dist/selftest/ui-text.test.d.ts +7 -0
- package/dist/selftest/ui-text.test.js +300 -0
- package/dist/shared/accounts/anthropic.d.ts +1 -1
- package/dist/shared/accounts/anthropic.js +9 -8
- package/dist/shared/accounts/index.d.ts +2 -0
- package/dist/shared/accounts/index.js +2 -0
- package/dist/shared/accounts/kinds/comet.d.ts +12 -0
- package/dist/shared/accounts/kinds/comet.js +64 -0
- package/dist/shared/accounts/kinds/perplexity.d.ts +8 -0
- package/dist/shared/accounts/kinds/perplexity.js +37 -0
- package/dist/shared/accounts/kinds.d.ts +24 -5
- package/dist/shared/accounts/kinds.js +86 -4
- package/dist/shared/accounts/payloads.d.ts +81 -0
- package/dist/shared/accounts/payloads.js +39 -1
- package/dist/shared/apps/agent-addons.d.ts +33 -5
- package/dist/shared/apps/agent-addons.js +95 -3
- package/dist/shared/apps/catalogue-agents-web.d.ts +14 -0
- package/dist/shared/apps/catalogue-agents-web.js +112 -0
- package/dist/shared/apps/catalogue-modding.js +32 -1
- package/dist/shared/apps/catalogue.d.ts +27 -3
- package/dist/shared/apps/catalogue.js +2 -1
- package/dist/shared/apps/index.d.ts +3 -1
- package/dist/shared/apps/index.js +3 -1
- package/dist/shared/channel/schema.d.ts +21 -3
- package/dist/shared/channel/schema.js +7 -0
- package/dist/shared/channel/secrets.d.ts +19 -0
- package/dist/shared/concurrency/index.d.ts +3 -0
- package/dist/shared/concurrency/index.js +3 -0
- package/dist/shared/concurrency/installer-retry.d.ts +6 -0
- package/dist/shared/concurrency/installer-retry.js +10 -0
- package/dist/shared/concurrency/limiter.d.ts +19 -0
- package/dist/shared/concurrency/limiter.js +67 -0
- package/dist/shared/concurrency/pools.d.ts +7 -0
- package/dist/shared/concurrency/pools.js +9 -0
- package/dist/shared/download/archive.d.ts +2 -0
- package/dist/shared/download/archive.js +11 -1
- package/dist/shared/download/bounded-fetch.d.ts +13 -0
- package/dist/shared/download/bounded-fetch.js +40 -0
- package/dist/shared/download/downloader.d.ts +5 -0
- package/dist/shared/download/downloader.js +50 -38
- package/dist/shared/download/index.d.ts +2 -1
- package/dist/shared/download/index.js +2 -1
- package/dist/shared/readiness.d.ts +2 -2
- package/dist/shared/readiness.js +2 -2
- package/dist/web/index.html +1 -1
- package/dist/web/{main-OUUQYNK4.js → main-CCILLX2M.js} +67 -67
- package/native/csharp/HcsHost/AssemblyInfo.cs +3 -3
- package/native/csharp/HostTools/AssemblyInfo.cs +3 -3
- package/native/csharp/StorageHelper/AssemblyInfo.cs +3 -3
- package/package.json +1 -1
- package/sandbox/addons/browser-use-mcp/requirements.in +1 -0
- package/sandbox/addons/browser-use-mcp/requirements.txt +2350 -0
- package/sandbox/addons/chrome-devtools-mcp/package-lock.json +38 -0
- package/sandbox/addons/chrome-devtools-mcp/package.json +7 -0
- package/sandbox/addons/comet-mcp/package-lock.json +1277 -0
- package/sandbox/addons/comet-mcp/package.json +7 -0
- package/sandbox/addons/perplexity-mcp/package-lock.json +1655 -0
- package/sandbox/addons/perplexity-mcp/package.json +7 -0
- package/sandbox/scripts/add-firewall-port.ps1 +18 -4
- package/sandbox/scripts/set-machine-environment.ps1 +30 -15
- package/sandbox/templates/fivem/README.txt +6 -2
- package/sandbox/templates/fivem/cs/Client/Client.csproj +15 -0
- package/sandbox/templates/fivem/cs/Client/ClientMain.cs +20 -0
- package/sandbox/templates/fivem/cs/Server/Server.csproj +14 -0
- package/sandbox/templates/fivem/cs/Server/ServerMain.cs +20 -0
- package/sandbox/templates/fivem/cs/fxmanifest.lua +11 -0
- package/sandbox/templates/fivem/js/client.js +12 -0
- package/sandbox/templates/fivem/js/fxmanifest.lua +9 -0
- package/sandbox/templates/fivem/js/server.js +6 -0
- package/sandbox/templates/fivem/lua/client.lua +8 -0
- package/sandbox/templates/fivem/lua/fxmanifest.lua +10 -0
- package/sandbox/templates/fivem/lua/server.lua +6 -0
- package/sandbox/templates/fivem/server.cfg +37 -0
- package/sandbox/templates/fivem/ts/build.js +17 -0
- package/sandbox/templates/fivem/ts/fxmanifest.lua +9 -0
- package/sandbox/templates/fivem/ts/package.json +16 -0
- package/sandbox/templates/fivem/ts/src/client/client.ts +12 -0
- package/sandbox/templates/fivem/ts/src/client/tsconfig.json +13 -0
- package/sandbox/templates/fivem/ts/src/server/server.ts +6 -0
- package/sandbox/templates/fivem/ts/src/server/tsconfig.json +13 -0
- package/schemas/config.schema.json +56 -27
- package/schemas/sandbox-config.schema.json +37 -14
|
@@ -33,6 +33,7 @@ import {
|
|
|
33
33
|
REQUEST_APP,
|
|
34
34
|
RunDir,
|
|
35
35
|
SAVED,
|
|
36
|
+
SYSTEM,
|
|
36
37
|
SandboxChannel,
|
|
37
38
|
SchemaNode,
|
|
38
39
|
ServerMessageSchema,
|
|
@@ -44,12 +45,16 @@ import {
|
|
|
44
45
|
__commonJS,
|
|
45
46
|
__require,
|
|
46
47
|
__toESM,
|
|
48
|
+
accessView,
|
|
49
|
+
accountsView,
|
|
47
50
|
action,
|
|
48
51
|
agentCommandsStatus,
|
|
49
52
|
agentEnv,
|
|
50
53
|
agentEnvPage,
|
|
54
|
+
agentEnvView,
|
|
51
55
|
agentPage,
|
|
52
56
|
agentsPage,
|
|
57
|
+
agentsView,
|
|
53
58
|
allowStorePath,
|
|
54
59
|
allowedAnswer,
|
|
55
60
|
allows,
|
|
@@ -57,11 +62,13 @@ import {
|
|
|
57
62
|
appIsOn,
|
|
58
63
|
appRows,
|
|
59
64
|
applyOverrides,
|
|
65
|
+
appsView,
|
|
60
66
|
askChoice,
|
|
61
67
|
assertSafeWorkspace,
|
|
62
68
|
attach,
|
|
63
69
|
auditArgv,
|
|
64
70
|
auditPage,
|
|
71
|
+
auditView,
|
|
65
72
|
autoMigrates,
|
|
66
73
|
c,
|
|
67
74
|
canAnimate,
|
|
@@ -78,6 +85,7 @@ import {
|
|
|
78
85
|
currentUserName,
|
|
79
86
|
customRows,
|
|
80
87
|
dataPage,
|
|
88
|
+
dataView,
|
|
81
89
|
defaultsContext,
|
|
82
90
|
definitionHandler,
|
|
83
91
|
describeCopy,
|
|
@@ -91,6 +99,7 @@ import {
|
|
|
91
99
|
engineLeftovers,
|
|
92
100
|
enginePage,
|
|
93
101
|
engineStatus,
|
|
102
|
+
engineView,
|
|
94
103
|
ensureStorageRoot,
|
|
95
104
|
entriesOf,
|
|
96
105
|
errMsg,
|
|
@@ -108,8 +117,10 @@ import {
|
|
|
108
117
|
githubLogout,
|
|
109
118
|
githubStatus,
|
|
110
119
|
githubTokenRowOf,
|
|
120
|
+
githubView,
|
|
111
121
|
guestWorkspaceOf,
|
|
112
122
|
healthPage,
|
|
123
|
+
healthView,
|
|
113
124
|
healthWith,
|
|
114
125
|
hereDir,
|
|
115
126
|
hostAgent,
|
|
@@ -127,6 +138,7 @@ import {
|
|
|
127
138
|
lastHealth,
|
|
128
139
|
launch,
|
|
129
140
|
ledgerToReopen,
|
|
141
|
+
link,
|
|
130
142
|
listAccounts,
|
|
131
143
|
listAgents,
|
|
132
144
|
listAudit,
|
|
@@ -136,6 +148,7 @@ import {
|
|
|
136
148
|
listSettings,
|
|
137
149
|
loadConfig,
|
|
138
150
|
logsPage,
|
|
151
|
+
logsView,
|
|
139
152
|
lookAtSandbox,
|
|
140
153
|
loosenedRequests,
|
|
141
154
|
measureFolder,
|
|
@@ -159,6 +172,7 @@ import {
|
|
|
159
172
|
previewGuest,
|
|
160
173
|
printJson,
|
|
161
174
|
projectsPage,
|
|
175
|
+
projectsView,
|
|
162
176
|
protectPrivateFolder,
|
|
163
177
|
provisionJoined,
|
|
164
178
|
readLocalConfig,
|
|
@@ -181,13 +195,16 @@ import {
|
|
|
181
195
|
sandboxPage,
|
|
182
196
|
sandboxPids,
|
|
183
197
|
sandboxStatus,
|
|
198
|
+
sandboxView,
|
|
184
199
|
serviceCategory,
|
|
185
200
|
servicePage,
|
|
186
201
|
sessionsPage,
|
|
187
202
|
sessionsToReopen,
|
|
203
|
+
sessionsView,
|
|
188
204
|
settingRow,
|
|
189
205
|
settingsOf,
|
|
190
206
|
settingsPage,
|
|
207
|
+
settingsView,
|
|
191
208
|
setup,
|
|
192
209
|
shouldReopen,
|
|
193
210
|
showData,
|
|
@@ -196,6 +213,7 @@ import {
|
|
|
196
213
|
spawnDetached,
|
|
197
214
|
staleMountNote,
|
|
198
215
|
storagePage,
|
|
216
|
+
storageView,
|
|
199
217
|
summary,
|
|
200
218
|
summaryText,
|
|
201
219
|
syncBack,
|
|
@@ -207,6 +225,7 @@ import {
|
|
|
207
225
|
trustStorePath,
|
|
208
226
|
updatesPage,
|
|
209
227
|
updatesStatus,
|
|
228
|
+
updatesView,
|
|
210
229
|
useSharedSandbox,
|
|
211
230
|
useTasklistCache,
|
|
212
231
|
userConfigPath,
|
|
@@ -221,16 +240,18 @@ import {
|
|
|
221
240
|
vpnLoginRowOf,
|
|
222
241
|
vpnLogout,
|
|
223
242
|
vpnStatus,
|
|
243
|
+
vpnView,
|
|
224
244
|
watch,
|
|
225
245
|
web,
|
|
226
246
|
webPage,
|
|
227
247
|
webServer,
|
|
228
248
|
webStatus,
|
|
249
|
+
webView,
|
|
229
250
|
whereOf,
|
|
230
251
|
withOperationCommands,
|
|
231
252
|
working,
|
|
232
253
|
writeJson
|
|
233
|
-
} from "./chunk-
|
|
254
|
+
} from "./chunk-USTRSHIE.js";
|
|
234
255
|
|
|
235
256
|
// node_modules/commander/lib/error.js
|
|
236
257
|
var require_error = __commonJS({
|
|
@@ -3950,6 +3971,7 @@ var COMMAND_LIST = [
|
|
|
3950
3971
|
"sandbox account status the service sign-ins (Epic, Steam, Unity, signing keys ...)",
|
|
3951
3972
|
"sandbox account import epic take this PC's Epic Games Launcher sign-in for sandboxes",
|
|
3952
3973
|
"sandbox account login cfx type a FiveM server key to keep for sandboxes",
|
|
3974
|
+
"sandbox account login perplexity type a Perplexity API key (or: import perplexity --from .env)",
|
|
3953
3975
|
"sandbox account logout steam forget a service sign-in",
|
|
3954
3976
|
"sandbox account save free --api-key save an Anthropic API key you paste in (not shown)"
|
|
3955
3977
|
],
|
|
@@ -3962,7 +3984,7 @@ var COMMAND_LIST = [
|
|
|
3962
3984
|
},
|
|
3963
3985
|
{
|
|
3964
3986
|
name: "name",
|
|
3965
|
-
description: "account name, or the service (status, import, login, logout): epic, steam, unity, cfx, keystore, play, expo or
|
|
3987
|
+
description: "account name, or the service (status, import, login, logout): epic, steam, unity, cfx, keystore, play, expo, appstore, perplexity or comet",
|
|
3966
3988
|
required: false,
|
|
3967
3989
|
choices: "accounts"
|
|
3968
3990
|
}
|
|
@@ -6096,6 +6118,8 @@ var App = class {
|
|
|
6096
6118
|
onKey = () => void 0;
|
|
6097
6119
|
/** The navigation on the left of every screen (none: no navigation column). */
|
|
6098
6120
|
nav = () => void 0;
|
|
6121
|
+
/** Opens another section of the menu (the shell sets it): what a link to a setting or a view does. */
|
|
6122
|
+
goTo = () => Promise.resolve();
|
|
6099
6123
|
/** The screens being shown, innermost last: a dialog is drawn over the one below it. */
|
|
6100
6124
|
shown = [];
|
|
6101
6125
|
redrawNow = null;
|
|
@@ -6205,6 +6229,9 @@ var App = class {
|
|
|
6205
6229
|
}
|
|
6206
6230
|
};
|
|
6207
6231
|
|
|
6232
|
+
// src/cli/menu/io-menu.ts
|
|
6233
|
+
import { spawn } from "node:child_process";
|
|
6234
|
+
|
|
6208
6235
|
// src/cli/menu/settings/ask-path.ts
|
|
6209
6236
|
function askPath(app, o) {
|
|
6210
6237
|
return app.pickPath({
|
|
@@ -6701,6 +6728,31 @@ var ValueEditor = class {
|
|
|
6701
6728
|
}
|
|
6702
6729
|
};
|
|
6703
6730
|
|
|
6731
|
+
// src/cli/menu/views.ts
|
|
6732
|
+
var MENU_VIEWS = [
|
|
6733
|
+
{ view: agentsView, section: "Agents" },
|
|
6734
|
+
{ view: agentEnvView, section: "Agents" },
|
|
6735
|
+
{ view: sessionsView, section: "Sessions" },
|
|
6736
|
+
{ view: sandboxView, section: "Sandbox" },
|
|
6737
|
+
{ view: settingsView, section: "Settings" },
|
|
6738
|
+
{ view: accountsView, section: "Accounts" },
|
|
6739
|
+
{ view: appsView, section: "Apps" },
|
|
6740
|
+
{ view: projectsView, section: "Sandbox" },
|
|
6741
|
+
{ view: healthView, section: "Maintenance" },
|
|
6742
|
+
{ view: dataView, section: "Maintenance" },
|
|
6743
|
+
{ view: storageView, section: "Maintenance" },
|
|
6744
|
+
{ view: logsView, section: "Maintenance" },
|
|
6745
|
+
{ view: auditView, section: "Maintenance" },
|
|
6746
|
+
{ view: updatesView, section: "Maintenance" },
|
|
6747
|
+
{ view: engineView, section: "Maintenance" },
|
|
6748
|
+
{ view: webView, section: "Maintenance" },
|
|
6749
|
+
{ view: accessView, section: "Maintenance" },
|
|
6750
|
+
// The Settings page draws the VPN row itself (its login is staged with the settings); the view lists its operations.
|
|
6751
|
+
{ view: vpnView, section: "Settings" },
|
|
6752
|
+
// The same for the GitHub token row.
|
|
6753
|
+
{ view: githubView, section: "Settings" }
|
|
6754
|
+
];
|
|
6755
|
+
|
|
6704
6756
|
// src/cli/menu/io-menu.ts
|
|
6705
6757
|
async function ask(app, where, q, said) {
|
|
6706
6758
|
const lines = [...said, ...q.lines ?? [], ..."problem" in q && q.problem ? [Theme.warn(q.problem)] : []];
|
|
@@ -6743,7 +6795,22 @@ async function ask(app, where, q, said) {
|
|
|
6743
6795
|
});
|
|
6744
6796
|
}
|
|
6745
6797
|
}
|
|
6746
|
-
function
|
|
6798
|
+
function placeOf(view) {
|
|
6799
|
+
const place = MENU_VIEWS.find((m) => m.view.id === view);
|
|
6800
|
+
if (!place) return void 0;
|
|
6801
|
+
return { section: place.section, ...view === "agentEnv" ? { category: "env" } : {} };
|
|
6802
|
+
}
|
|
6803
|
+
function openUrl(href) {
|
|
6804
|
+
if (!/^https:\/\/github\.com\//.test(href)) return;
|
|
6805
|
+
const child = spawn(SYSTEM.cmd(), ["/c", "start", '""', href.replace(/&/g, "^&")], {
|
|
6806
|
+
stdio: "ignore",
|
|
6807
|
+
detached: true,
|
|
6808
|
+
windowsHide: true
|
|
6809
|
+
});
|
|
6810
|
+
child.on("error", () => void 0);
|
|
6811
|
+
child.unref();
|
|
6812
|
+
}
|
|
6813
|
+
function follow(target, app) {
|
|
6747
6814
|
switch (target.kind) {
|
|
6748
6815
|
case "terminal":
|
|
6749
6816
|
return { exit: { kind: "run", argv: ["attach", target.session] } };
|
|
@@ -6751,8 +6818,17 @@ function follow(target) {
|
|
|
6751
6818
|
return { exit: { kind: "run", argv: ["launch", "--harness", target.agent] } };
|
|
6752
6819
|
case "command":
|
|
6753
6820
|
return { exit: { kind: "run", argv: [...target.argv] } };
|
|
6754
|
-
case "view":
|
|
6755
|
-
|
|
6821
|
+
case "view": {
|
|
6822
|
+
const place = placeOf(target.view);
|
|
6823
|
+
if (!place || !app) return {};
|
|
6824
|
+
return app.goTo(place.section, { category: place.category }).then(() => ({}));
|
|
6825
|
+
}
|
|
6826
|
+
case "setting":
|
|
6827
|
+
if (!app) return {};
|
|
6828
|
+
return app.goTo("Settings", { search: target.key }).then(() => ({}));
|
|
6829
|
+
case "url":
|
|
6830
|
+
openUrl(target.href);
|
|
6831
|
+
return { notice: Theme.muted("Opened " + target.href + " in your browser.") };
|
|
6756
6832
|
}
|
|
6757
6833
|
}
|
|
6758
6834
|
var MenuOperations = class {
|
|
@@ -6764,7 +6840,7 @@ var MenuOperations = class {
|
|
|
6764
6840
|
runner;
|
|
6765
6841
|
/** Does what an action of a page says: follows a link, or asks for its fields and runs its operation. */
|
|
6766
6842
|
async perform(action2, where, busy, onOutput) {
|
|
6767
|
-
if (action2.kind === "link") return follow(action2.target);
|
|
6843
|
+
if (action2.kind === "link") return follow(action2.target, this.app);
|
|
6768
6844
|
const def = operationById(action2.op);
|
|
6769
6845
|
if (!def) return { notice: Theme.error(Theme.glyph.cross + " Unknown operation " + action2.op + ".") };
|
|
6770
6846
|
const answers = await this.fields(action2, def, where);
|
|
@@ -6790,6 +6866,15 @@ var MenuOperations = class {
|
|
|
6790
6866
|
}
|
|
6791
6867
|
return answers;
|
|
6792
6868
|
}
|
|
6869
|
+
/** A failure that names a fix: a dialog with the fix as a button; its result replaces the failure notice. */
|
|
6870
|
+
async offerFix(problem, where, busy) {
|
|
6871
|
+
const fix = problem.action;
|
|
6872
|
+
const def = fix ? operationById(fix.op) : void 0;
|
|
6873
|
+
if (!fix || !def) return void 0;
|
|
6874
|
+
const yes = await this.app.ask(problem.message, problem.fix ? [problem.fix] : [], fix.label);
|
|
6875
|
+
if (!yes) return void 0;
|
|
6876
|
+
return await this.run(def, fix.input ?? {}, where, busy) ?? Theme.ok(Theme.glyph.ok + " Done.");
|
|
6877
|
+
}
|
|
6793
6878
|
/**
|
|
6794
6879
|
* Runs a definition with this input and returns the notice to show: its text (✓), the problem and its fix (✘), or
|
|
6795
6880
|
* undefined when a question was declined (nothing changed, nothing to say).
|
|
@@ -6810,7 +6895,8 @@ var MenuOperations = class {
|
|
|
6810
6895
|
if (e instanceof Cancelled) return void 0;
|
|
6811
6896
|
const problem = toWireError(e);
|
|
6812
6897
|
if (problem.kind === "bug") return Theme.error(Theme.glyph.cross + " " + errMsg(e));
|
|
6813
|
-
|
|
6898
|
+
const notice = Theme.error(Theme.glyph.cross + " " + problem.message) + (problem.fix ? Theme.muted(" " + problem.fix) : "");
|
|
6899
|
+
return await this.offerFix(problem, where, busy) ?? notice;
|
|
6814
6900
|
}
|
|
6815
6901
|
}
|
|
6816
6902
|
};
|
|
@@ -7135,7 +7221,7 @@ function accountsOptions(m) {
|
|
|
7135
7221
|
...m.services.map((s) => ({
|
|
7136
7222
|
id: serviceCategory(s.kind),
|
|
7137
7223
|
label: s.label,
|
|
7138
|
-
description: "Your " + s.label + " sign-in for sandboxes that use " + s.
|
|
7224
|
+
description: "Your " + s.label + " sign-in for sandboxes that use " + s.usedFor + "."
|
|
7139
7225
|
}))
|
|
7140
7226
|
],
|
|
7141
7227
|
items: [
|
|
@@ -7794,8 +7880,13 @@ function startRow(item2, m, cwd) {
|
|
|
7794
7880
|
function envView(m) {
|
|
7795
7881
|
return m.claudeEnv ? menuView(agentEnvPage(m.claudeEnv), { category: "env", refresh: false }) : void 0;
|
|
7796
7882
|
}
|
|
7883
|
+
function lastStart(argv) {
|
|
7884
|
+
const at = argv.indexOf("--harness");
|
|
7885
|
+
const agent = at >= 0 ? argv[at + 1] : argv[0];
|
|
7886
|
+
return agent ?? "last start";
|
|
7887
|
+
}
|
|
7797
7888
|
function agentsOptions(m, cwd = process.cwd()) {
|
|
7798
|
-
const
|
|
7889
|
+
const view = startView(m);
|
|
7799
7890
|
const env = envView(m);
|
|
7800
7891
|
const commands = commandsView(m);
|
|
7801
7892
|
return {
|
|
@@ -7808,11 +7899,11 @@ function agentsOptions(m, cwd = process.cwd()) {
|
|
|
7808
7899
|
label: "Repeat last",
|
|
7809
7900
|
category: "start",
|
|
7810
7901
|
section: "Quick start",
|
|
7811
|
-
hint: Theme.muted(Text.truncate(
|
|
7812
|
-
description: "
|
|
7902
|
+
hint: Theme.muted(Text.truncate(lastStart(m.last), 50)),
|
|
7903
|
+
description: "Starts the same agent again with the same options."
|
|
7813
7904
|
}
|
|
7814
7905
|
] : [],
|
|
7815
|
-
...
|
|
7906
|
+
...view.items.map((item2) => startRow(item2, m, cwd)),
|
|
7816
7907
|
...env?.items ?? [],
|
|
7817
7908
|
...commands.items,
|
|
7818
7909
|
{
|
|
@@ -7869,7 +7960,7 @@ function agentsOptions(m, cwd = process.cwd()) {
|
|
|
7869
7960
|
}))
|
|
7870
7961
|
],
|
|
7871
7962
|
enterLabel: (category, id) => ENTER[id ?? ""] ?? (id?.startsWith("agent:") ? "start" : id?.startsWith("host:") ? "run" : category === "host" ? commands.enterLabel(category, id) : "open"),
|
|
7872
|
-
actions: (category) => category === "start" ?
|
|
7963
|
+
actions: (category) => category === "start" ? view.actions : category === "env" ? env?.actions ?? [] : category === "host" ? commands.actions : []
|
|
7873
7964
|
};
|
|
7874
7965
|
}
|
|
7875
7966
|
var ENTER = {
|
|
@@ -8246,7 +8337,12 @@ var NO_UPDATES = {
|
|
|
8246
8337
|
settings: { pending: [], error: null }
|
|
8247
8338
|
};
|
|
8248
8339
|
function logsMenu(files) {
|
|
8249
|
-
|
|
8340
|
+
const follow2 = link({ kind: "command", argv: ["logs", "--follow"] }, "Follow the newest log", {
|
|
8341
|
+
key: "f",
|
|
8342
|
+
verb: "follow in the terminal",
|
|
8343
|
+
importance: 2
|
|
8344
|
+
});
|
|
8345
|
+
return menuView({ ...logsPage(files), empty: void 0, actions: [follow2] }, { category: "logs", refresh: false });
|
|
8250
8346
|
}
|
|
8251
8347
|
function auditMenu(m) {
|
|
8252
8348
|
return m.audit ? menuView(auditPage(m.audit), { category: "activity", prefix: "audit:", refresh: false }) : void 0;
|
|
@@ -8523,18 +8619,18 @@ var CATEGORIES3 = [
|
|
|
8523
8619
|
function statusView(m) {
|
|
8524
8620
|
return menuView(sandboxPage(m.report), { category: "status", prefix: "status:", refresh: false });
|
|
8525
8621
|
}
|
|
8526
|
-
function
|
|
8622
|
+
function projectsView2(m) {
|
|
8527
8623
|
return menuView(projectsPage(m.projects), { category: "projects", refresh: false });
|
|
8528
8624
|
}
|
|
8529
8625
|
function viewFor(m, category) {
|
|
8530
|
-
if (category === "projects") return
|
|
8626
|
+
if (category === "projects") return projectsView2(m);
|
|
8531
8627
|
if (category === "status" || category === void 0) return statusView(m);
|
|
8532
8628
|
return void 0;
|
|
8533
8629
|
}
|
|
8534
8630
|
function sandboxOptions(m) {
|
|
8535
8631
|
const running = m.report.sandbox.running;
|
|
8536
8632
|
const status = statusView(m);
|
|
8537
|
-
const projects =
|
|
8633
|
+
const projects = projectsView2(m);
|
|
8538
8634
|
const statusItems = [...running ? [] : startRows(m.defaultAgent, "status"), ...status.items];
|
|
8539
8635
|
const noDatabases = m.databases ? [] : running ? [
|
|
8540
8636
|
{
|
|
@@ -8664,11 +8760,17 @@ var SandboxPage = class extends ListPage {
|
|
|
8664
8760
|
};
|
|
8665
8761
|
|
|
8666
8762
|
// src/cli/menu/pages/sessions-page.ts
|
|
8667
|
-
function
|
|
8668
|
-
|
|
8763
|
+
function sessionsMenu(m) {
|
|
8764
|
+
const resume2 = link({ kind: "command", argv: ["resume"] }, "Reopen last sessions", {
|
|
8765
|
+
key: "o",
|
|
8766
|
+
verb: "reopen last sessions",
|
|
8767
|
+
importance: 2
|
|
8768
|
+
});
|
|
8769
|
+
const page = sessionsPage({ ...m, wide: false });
|
|
8770
|
+
return menuView({ ...page, actions: [...page.actions ?? [], resume2] });
|
|
8669
8771
|
}
|
|
8670
8772
|
function sessionsOptions(m) {
|
|
8671
|
-
const v =
|
|
8773
|
+
const v = sessionsMenu(m);
|
|
8672
8774
|
return { path: [], items: v.items, actions: v.actions, enterLabel: v.enterLabel };
|
|
8673
8775
|
}
|
|
8674
8776
|
var SessionsPage = class extends ListPage {
|
|
@@ -8689,7 +8791,7 @@ var SessionsPage = class extends ListPage {
|
|
|
8689
8791
|
return sessionsOptions(this.model);
|
|
8690
8792
|
}
|
|
8691
8793
|
async act(result) {
|
|
8692
|
-
const chosen =
|
|
8794
|
+
const chosen = sessionsMenu(this.model).resolve(result);
|
|
8693
8795
|
if (!chosen) return {};
|
|
8694
8796
|
if (chosen.kind === "refresh") return { reload: true };
|
|
8695
8797
|
return this.operations.perform(chosen.action, [this.label], (text2) => this.busy(text2));
|
|
@@ -8826,7 +8928,18 @@ var SettingsPage = class extends ListPage {
|
|
|
8826
8928
|
lastFailure: null
|
|
8827
8929
|
};
|
|
8828
8930
|
/** Whether a GitHub token is saved (never the token): the token row needs only its state. */
|
|
8829
|
-
github = {
|
|
8931
|
+
github = {
|
|
8932
|
+
shareToken: false,
|
|
8933
|
+
gitAccess: "full",
|
|
8934
|
+
token: "none",
|
|
8935
|
+
kind: null,
|
|
8936
|
+
savedAt: null,
|
|
8937
|
+
login: null,
|
|
8938
|
+
expiresAt: null,
|
|
8939
|
+
repoCount: null,
|
|
8940
|
+
checkedAt: null,
|
|
8941
|
+
tokenUrl: ""
|
|
8942
|
+
};
|
|
8830
8943
|
get file() {
|
|
8831
8944
|
return this.files[this.scope];
|
|
8832
8945
|
}
|
|
@@ -9099,11 +9212,11 @@ var MenuStateSchema = external_exports.strictObject({
|
|
|
9099
9212
|
function stateFile(dir) {
|
|
9100
9213
|
return new JsonFile(MenuStateSchema, path8.join(dir, "menu-state.json"));
|
|
9101
9214
|
}
|
|
9102
|
-
function viewToState(
|
|
9215
|
+
function viewToState(view, labels) {
|
|
9103
9216
|
const screens = {};
|
|
9104
|
-
for (const [label, screen] of Object.entries(
|
|
9217
|
+
for (const [label, screen] of Object.entries(view.screens))
|
|
9105
9218
|
if (labels.includes(label) && (screen.category || screen.search)) screens[label] = screen;
|
|
9106
|
-
return { section: labels[
|
|
9219
|
+
return { section: labels[view.section] ?? labels[0] ?? "", screens };
|
|
9107
9220
|
}
|
|
9108
9221
|
function stateToView(state, labels) {
|
|
9109
9222
|
const section = labels.indexOf(state.section);
|
|
@@ -9120,9 +9233,9 @@ function readMenuView(labels, dir = userDir()) {
|
|
|
9120
9233
|
return void 0;
|
|
9121
9234
|
}
|
|
9122
9235
|
}
|
|
9123
|
-
function saveMenuView(
|
|
9236
|
+
function saveMenuView(view, labels, dir = userDir()) {
|
|
9124
9237
|
try {
|
|
9125
|
-
stateFile(dir).write(viewToState(
|
|
9238
|
+
stateFile(dir).write(viewToState(view, labels));
|
|
9126
9239
|
} catch {
|
|
9127
9240
|
}
|
|
9128
9241
|
}
|
|
@@ -9143,6 +9256,7 @@ var Shell = class {
|
|
|
9143
9256
|
this.draft = draft;
|
|
9144
9257
|
this.afterSave = afterSave;
|
|
9145
9258
|
app.nav = () => this.nav();
|
|
9259
|
+
app.goTo = (section, where) => this.goTo(section, where);
|
|
9146
9260
|
}
|
|
9147
9261
|
app;
|
|
9148
9262
|
pages;
|
|
@@ -9187,10 +9301,10 @@ var Shell = class {
|
|
|
9187
9301
|
return { section: this.active, screens: Object.fromEntries(this.screens) };
|
|
9188
9302
|
}
|
|
9189
9303
|
/** Opens the section a view names and puts each section back where it was (what is gone is ignored). */
|
|
9190
|
-
async restore(
|
|
9304
|
+
async restore(view) {
|
|
9191
9305
|
this.restored.clear();
|
|
9192
|
-
for (const [label, screen] of Object.entries(
|
|
9193
|
-
await this.openTab(
|
|
9306
|
+
for (const [label, screen] of Object.entries(view.screens)) this.screens.set(label, screen);
|
|
9307
|
+
await this.openTab(view.section);
|
|
9194
9308
|
}
|
|
9195
9309
|
/** Opens a section by index (loads its data); the first time, it goes back to the category and search it had. */
|
|
9196
9310
|
async openTab(index) {
|
|
@@ -9205,6 +9319,15 @@ var Shell = class {
|
|
|
9205
9319
|
await this.page.selectCategory(wanted.category);
|
|
9206
9320
|
if (wanted?.search) this.page.restoreSearch?.(wanted.search);
|
|
9207
9321
|
}
|
|
9322
|
+
/** Opens a section by name, on a category and/or with a search typed (a link from another page). */
|
|
9323
|
+
async goTo(section, where = {}) {
|
|
9324
|
+
const index = this.pages.findIndex((p) => p.label === section);
|
|
9325
|
+
if (index < 0) return;
|
|
9326
|
+
await this.openTab(index);
|
|
9327
|
+
if (where.category) await this.page.selectCategory(where.category);
|
|
9328
|
+
if (where.search) this.page.restoreSearch?.(where.search);
|
|
9329
|
+
this.setFocus("list");
|
|
9330
|
+
}
|
|
9208
9331
|
/** Puts the keyboard in the navigation or in the list. */
|
|
9209
9332
|
setFocus(focus) {
|
|
9210
9333
|
this.focus = focus;
|
|
@@ -9353,10 +9476,10 @@ var Menu = class {
|
|
|
9353
9476
|
status() {
|
|
9354
9477
|
const folder = Theme.muted(Text.middle(process.cwd(), 70));
|
|
9355
9478
|
if (!isSandboxRunning()) return Theme.muted(Theme.glyph.off + " No sandbox running") + " " + folder;
|
|
9356
|
-
const
|
|
9357
|
-
if (
|
|
9358
|
-
return Theme.ok(Theme.glyph.on + " " +
|
|
9359
|
-
|
|
9479
|
+
const view = lookAtSandbox(this.ctx);
|
|
9480
|
+
if (view.line)
|
|
9481
|
+
return Theme.ok(Theme.glyph.on + " " + view.line) + Theme.muted(
|
|
9482
|
+
view.limited ? ". You can use it when they share it, or start your own after it stops." : ". Its window is on their desktop; use its agents here."
|
|
9360
9483
|
);
|
|
9361
9484
|
const n = new SandboxChannel(this.ctx.dataPath).runningSessions().length;
|
|
9362
9485
|
return Theme.ok(Theme.glyph.on + " Sandbox running") + Theme.muted(" \xB7 " + n + " session" + (n === 1 ? "" : "s")) + " " + folder;
|
|
@@ -9842,7 +9965,7 @@ async function logs(ctx) {
|
|
|
9842
9965
|
}
|
|
9843
9966
|
|
|
9844
9967
|
// src/cli/commands/maintenance/config.ts
|
|
9845
|
-
import { spawn } from "node:child_process";
|
|
9968
|
+
import { spawn as spawn2 } from "node:child_process";
|
|
9846
9969
|
import fs7 from "node:fs";
|
|
9847
9970
|
import path11 from "node:path";
|
|
9848
9971
|
import { pathToFileURL } from "node:url";
|
|
@@ -9864,7 +9987,7 @@ async function initConfig() {
|
|
|
9864
9987
|
if (answer === "cancel") return 0;
|
|
9865
9988
|
if (answer === "open") {
|
|
9866
9989
|
refuseInSelfTest("open files");
|
|
9867
|
-
|
|
9990
|
+
spawn2(system32("notepad.exe"), [file], { detached: true, stdio: "ignore" }).unref();
|
|
9868
9991
|
console.log("Opened " + file + ".");
|
|
9869
9992
|
return 0;
|
|
9870
9993
|
}
|
|
@@ -10097,30 +10220,30 @@ var RemoteMenu = class {
|
|
|
10097
10220
|
});
|
|
10098
10221
|
if (picked.kind !== "pick") return;
|
|
10099
10222
|
at = picked.value;
|
|
10100
|
-
const
|
|
10101
|
-
if (
|
|
10223
|
+
const view = views.find((v) => v.id === picked.value);
|
|
10224
|
+
if (view) await this.showView(view);
|
|
10102
10225
|
}
|
|
10103
10226
|
}
|
|
10104
|
-
async page(
|
|
10105
|
-
const inputs = viewInputs(
|
|
10227
|
+
async page(view) {
|
|
10228
|
+
const inputs = viewInputs(view, {});
|
|
10106
10229
|
const data = {};
|
|
10107
|
-
for (const [name, query] of Object.entries(
|
|
10230
|
+
for (const [name, query] of Object.entries(view.queries))
|
|
10108
10231
|
data[name] = await this.client.run(query.id, inputs[name], NO_QUESTIONS);
|
|
10109
|
-
return
|
|
10232
|
+
return view.build(data, {});
|
|
10110
10233
|
}
|
|
10111
|
-
async showView(
|
|
10234
|
+
async showView(view) {
|
|
10112
10235
|
let notice;
|
|
10113
10236
|
for (; ; ) {
|
|
10114
10237
|
let page;
|
|
10115
10238
|
try {
|
|
10116
|
-
page = await this.page(
|
|
10239
|
+
page = await this.page(view);
|
|
10117
10240
|
} catch (e) {
|
|
10118
|
-
await this.app.message({ path: [this.title(),
|
|
10241
|
+
await this.app.message({ path: [this.title(), view.title], lines: [safeText(errMsg(e))], tone: "error" });
|
|
10119
10242
|
return;
|
|
10120
10243
|
}
|
|
10121
10244
|
const mv = menuView(page);
|
|
10122
10245
|
const result = await this.app.list({
|
|
10123
|
-
path: [this.title(),
|
|
10246
|
+
path: [this.title(), view.title],
|
|
10124
10247
|
intro: page.notice ? [safeText(page.notice.text)] : void 0,
|
|
10125
10248
|
items: mv.items,
|
|
10126
10249
|
actions: mv.actions,
|
|
@@ -10134,10 +10257,10 @@ var RemoteMenu = class {
|
|
|
10134
10257
|
if (!chosen || chosen.kind === "refresh") continue;
|
|
10135
10258
|
const action2 = chosen.action;
|
|
10136
10259
|
if (action2.kind === "link") {
|
|
10137
|
-
notice = action2.target.kind === "terminal" ? Theme.muted("Attach to it from your own terminal
|
|
10260
|
+
notice = action2.target.kind === "terminal" ? Theme.muted("Attach to it from your own terminal (session " + safeText(action2.target.session) + ").") : Theme.muted("That opens on " + safeText(this.owner) + "'s side only.");
|
|
10138
10261
|
continue;
|
|
10139
10262
|
}
|
|
10140
|
-
const done = await this.operations.perform(action2, [this.title(),
|
|
10263
|
+
const done = await this.operations.perform(action2, [this.title(), view.title], (text2) => {
|
|
10141
10264
|
notice = text2;
|
|
10142
10265
|
this.app.redraw();
|
|
10143
10266
|
});
|
|
@@ -10407,6 +10530,7 @@ function report(e) {
|
|
|
10407
10530
|
if (e instanceof UserError) {
|
|
10408
10531
|
console.error(c.red("Error: ") + plainText(e.message));
|
|
10409
10532
|
if (e.fix) console.error(" Fix: " + plainText(e.fix));
|
|
10533
|
+
if (e.action?.cli) console.error(" Run: " + plainText(e.action.cli));
|
|
10410
10534
|
return 1;
|
|
10411
10535
|
}
|
|
10412
10536
|
console.error(c.red("Unexpected error: ") + errMsg(e));
|