fix: use fs backend for host apply-patch

This commit is contained in:
Codex
2026-06-26 18:12:44 +00:00
parent c8fb148db3
commit 590feb7d9f
7 changed files with 175 additions and 20 deletions
+4 -1
View File
@@ -7,6 +7,7 @@ import { type UniDeskConfig } from "./config";
import { type RemoteCliOptions } from "./remote-options";
import {
buildWindowsPowerShellInvocation,
createPosixApplyPatchFileSystem,
createWindowsApplyPatchFileSystem,
createSshStdoutForwarder,
formatSshFailureHint,
@@ -904,7 +905,9 @@ async function runRemoteSshOverFrontend(session: FrontendSession, target: string
if ((normalizedArgs[0] ?? "") === "apply-patch") {
const executor: ApplyPatchV2Executor = invocation.route.plane === "win"
? { fs: createWindowsApplyPatchFileSystem(invocation, (remoteCommand, input) => runRemoteSshWebSocketCaptureRemoteCommand(session, invocation, remoteCommand, input)) }
: { run: (command, input) => runRemoteSshWebSocketCapture(session, invocation, command, input) };
: invocation.route.plane === "host"
? { fs: createPosixApplyPatchFileSystem(invocation, (command, input) => runRemoteSshWebSocketCapture(session, invocation, command, input)) }
: { run: (command, input) => runRemoteSshWebSocketCapture(session, invocation, command, input) };
return await runApplyPatchV2({
executor,
stdin: process.stdin,