mirror of
https://github.com/anomalyco/opencode.git
synced 2026-05-24 13:54:07 +00:00
fix: terminal in desktop
This commit is contained in:
parent
1d68c34be6
commit
47eaef468f
1 changed files with 5 additions and 1 deletions
|
|
@ -114,8 +114,12 @@ export namespace Pty {
|
|||
const id = Identifier.create("pty", false)
|
||||
const command = input.command || Shell.preferred()
|
||||
const args = input.args || []
|
||||
if (command.endsWith("sh")) {
|
||||
args.push("-l")
|
||||
}
|
||||
|
||||
const cwd = input.cwd || Instance.directory
|
||||
const env = { ...process.env, ...input.env } as Record<string, string>
|
||||
const env = { ...process.env, ...input.env, TERM: "xterm-256color" } as Record<string, string>
|
||||
log.info("creating session", { id, cmd: command, args, cwd })
|
||||
|
||||
const spawn = await pty()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue