| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
Sorry, something went wrong.
When running `opencode attach` without `--dir`, the TUI session previously used the server's process.cwd() as its working directory. This changes the default to send the attaching client's cwd so the session operates in the directory where the attach command was invoked.
|
Thanks for your contribution! This PR doesn't have a linked issue. All PRs must reference an existing issue. Please:
See CONTRIBUTING.md for details. |
Sorry, something went wrong.
|
The following comment was made by an LLM, it may be inaccurate: Based on my search, I found several potentially related PRs: Most Relevant:
Less Relevant but Related:
I recommend checking PRs #13781 and #13630 most closely, as they appear to be addressing similar TUI and attach directory handling issues. |
Sorry, something went wrong.
| Back | FazBrowse Home | New Git URL |
Adding support for server attachments linking to local TUI spawn directory
When running opencode attach without --dir, the TUI session previously fell back to the server's process.cwd() as its working directory. This changes the default to use the attaching client's process.cwd() so the session operates in the directory where the attach command was invoked.
Change
One-line change in packages/opencode/src/cli/cmd/tui/attach.ts:
When directory was undefined, the SDK client skipped sending the x-opencode-directory header, causing the server middleware to fall back to its own process.cwd(). Now it always sends the client's cwd, matching the behavior users would expect.