opencode/packages/cli/test
Kit Langton b171a295df fix(cli): adopt the login shell environment in the background service
A managed service elected by a GUI client (the desktop app, an editor, a
login item) inherits launchd's environment: PATH is /usr/bin:/bin:/usr/sbin:/sbin
and nothing exported from .zshrc or .bashrc exists. Every process the server
spawns extends process.env, so stdio MCP servers using #!/usr/bin/env node,
npx, uvx, formatters, and hooks fail with "Connection closed" while the bash
tool, which prefers the client's terminal environment, keeps working.

Resolve the user's interactive login shell once at service startup when the
inherited environment did not come from a shell, and adopt it before anything
reads process.env.
2026-09-16 11:57:09 -07:00
..
acp test(cli): align ACP fixture contracts (#49251) 2026-09-16 00:33:18 +00:00
fixture refactor: restrict reflective access (#48860) 2026-09-13 17:08:43 -04:00
run refactor(protocol): simplify interactive resources 2026-09-15 18:23:47 -04:00
auth.test.ts refactor(protocol): consolidate server status 2026-09-13 16:56:22 -04:00
config.test.ts refactor: restrict reflective access (#48860) 2026-09-13 17:08:43 -04:00
cors.test.ts refactor(packages): migrate to the opencode npm scope (#47852) 2026-09-07 17:19:33 -04:00
cpu-profile.test.ts refactor(packages): migrate to the opencode npm scope (#47852) 2026-09-07 17:19:33 -04:00
debug-config.test.ts refactor(protocol): consolidate server status 2026-09-13 16:56:22 -04:00
debug-paths.test.ts feat(cli): restore debug paths command (#45063) 2026-08-25 23:01:43 +02:00
env.test.ts feat(tui): inherit terminal environment per session (#42957) 2026-08-17 20:18:28 +00:00
import-boundaries.test.ts refactor(packages): migrate to the opencode npm scope (#47852) 2026-09-07 17:19:33 -04:00
import-export.test.ts refactor(protocol): normalize session resources 2026-09-14 17:51:48 -04:00
mini-config.test.ts refactor(protocol): consolidate server status 2026-09-13 16:56:22 -04:00
mini-host.test.ts mini v2 v2 (#46410) 2026-08-31 22:03:27 +02:00
mini.test.ts refactor(protocol): consolidate server status 2026-09-13 16:56:22 -04:00
node-assets.test.ts feat(cli): embed persistent PTY service binaries (#44970) 2026-08-25 13:19:48 -04:00
server-connection.test.ts refactor(protocol): consolidate server status 2026-09-13 16:56:22 -04:00
service.test.ts refactor(protocol): consolidate server status 2026-09-13 16:56:22 -04:00
session-target.test.ts refactor(protocol): remove workspace API 2026-09-13 17:39:23 -04:00
shell-environment.test.ts fix(cli): adopt the login shell environment in the background service 2026-09-16 11:57:09 -07:00
standalone.test.ts fix: eliminate flaky CI races (#43522) 2026-08-19 22:12:41 +00:00
stats.test.ts refactor(packages): migrate to the opencode npm scope (#47852) 2026-09-07 17:19:33 -04:00
updater-install.test.ts feat(cli): rename command to opencode 2026-09-11 15:03:45 -04:00
updater-poll.test.ts feat(cli): restore automatic update policy (#47161) 2026-09-04 12:58:30 -04:00
upgrade.test.ts feat(cli): port the upgrade command to v2 (#46183) 2026-08-31 16:00:22 -05:00
vite-refresh.test.ts fix(cli): recover dev hot reloads and preserve routes (#47979) 2026-09-08 11:19:51 -04:00
vite-route.test.tsx fix(cli): recover dev hot reloads and preserve routes (#47979) 2026-09-08 11:19:51 -04:00
web-ui.test.ts refactor(protocol): consolidate server status 2026-09-13 16:56:22 -04:00