From 2863b715132fe29e53089e06f105943d1df0b3b4 Mon Sep 17 00:00:00 2001 From: Can Celik Date: Wed, 5 Aug 2026 19:34:24 +0300 Subject: feat(windows): support remote attach to unix hosts (#2329) * feat(windows): support remote attach to unix hosts * fix(remote): preserve unix bridge behavior --- src/platform/mod.rs | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) (limited to 'src/platform/mod.rs') diff --git a/src/platform/mod.rs b/src/platform/mod.rs index 38d797d1..d8613be4 100644 --- a/src/platform/mod.rs +++ b/src/platform/mod.rs @@ -52,7 +52,6 @@ fn configure_background_command_platform(_command: &mut std::process::Command) { #[derive(Debug, Clone, Copy, PartialEq, Eq)] pub(crate) struct PlatformCapabilities { pub(crate) live_handoff: bool, - pub(crate) remote_attach: bool, pub(crate) direct_terminal_attach: bool, pub(crate) preserve_legacy_doubled_escape_input: bool, } @@ -60,7 +59,6 @@ pub(crate) struct PlatformCapabilities { pub(crate) const fn capabilities() -> PlatformCapabilities { PlatformCapabilities { live_handoff: cfg!(unix), - remote_attach: cfg!(unix), direct_terminal_attach: cfg!(unix), preserve_legacy_doubled_escape_input: cfg!(target_os = "macos"), } @@ -137,14 +135,11 @@ pub struct ClipboardCommand { } #[derive(Debug, Clone, PartialEq, Eq)] -// Windows does not wire clipboard-image bridging into semantic input yet. -#[cfg_attr(windows, allow(dead_code))] pub struct ClipboardImage { pub bytes: Vec, pub extension: &'static str, } -#[cfg(unix)] #[derive(Debug, PartialEq, Eq)] pub(crate) enum LimitedRead { Empty, @@ -152,7 +147,6 @@ pub(crate) enum LimitedRead { Oversized, } -#[cfg(unix)] pub(crate) fn read_limited_reader( mut reader: impl std::io::Read, max_bytes: usize, @@ -190,6 +184,16 @@ pub(crate) fn read_limited_reader( } } +#[derive(Debug, Clone)] +pub(crate) struct RemoteSshConfigPaths { + pub(crate) user_config: Option, + pub(crate) system_config: Option, + pub(crate) multiplexing: bool, +} + +#[cfg(unix)] +mod unix_common; + #[cfg(target_os = "linux")] mod linux; #[cfg(target_os = "linux")] -- cgit v1.2.3