Skip to content

Commit 85ddedb

Browse files
skulidropekclaude
andcommitted
fix(app): SSH command opens targetDir on connect
Adds -t and "cd DIR && exec \$SHELL" so the SSH session starts directly in the project folder instead of the default home. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
1 parent 18aea42 commit 85ddedb

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

packages/app/src/web/app-ready-terminal-pane.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -214,7 +214,7 @@ const VsCodeAccessPanel = (
214214
}
215215
): JSX.Element => {
216216
const cfSshCommand = cfState.tag === "ready"
217-
? `ssh -o "ProxyCommand=cloudflared access ssh --hostname %h" ${info.sshUser}@${cfState.hostname}`
217+
? `ssh -o "ProxyCommand=cloudflared access ssh --hostname %h" -t ${info.sshUser}@${cfState.hostname} "cd ${info.targetDir} && exec \\$SHELL"`
218218
: null
219219
const cfVscodeUri = cfState.tag === "ready"
220220
? `vscode://ms-vscode-remote.remote-ssh/open?hostName=${encodeURIComponent(`${info.sshUser}@${cfState.hostname}`)}&folder=${encodeURIComponent(info.targetDir)}`

0 commit comments

Comments
 (0)