diff --git a/packages/opencode/src/cli/cmd/tui/attach.ts b/packages/opencode/src/cli/cmd/tui/attach.ts index 8b8979c831c7..6dc59f424651 100644 --- a/packages/opencode/src/cli/cmd/tui/attach.ts +++ b/packages/opencode/src/cli/cmd/tui/attach.ts @@ -32,7 +32,7 @@ export const AttachCommand = cmd({ win32DisableProcessedInput() const directory = (() => { - if (!args.dir) return undefined + if (!args.dir) return process.cwd() try { process.chdir(args.dir) return process.cwd()