diff --git a/crates/tty7-core/src/daemon/pane.rs b/crates/tty7-core/src/daemon/pane.rs index a712d9e1..0713badc 100644 --- a/crates/tty7-core/src/daemon/pane.rs +++ b/crates/tty7-core/src/daemon/pane.rs @@ -1670,7 +1670,6 @@ impl DaemonPane { } } - #[allow(dead_code)] pub fn ssh_connection(&self) -> Option> { match &self.backend { PaneBackend::NativeSsh(b) => b.connection.lock().unwrap().upgrade(), diff --git a/crates/tty7-core/src/daemon/protocol.rs b/crates/tty7-core/src/daemon/protocol.rs index 3eda0452..4348a757 100644 --- a/crates/tty7-core/src/daemon/protocol.rs +++ b/crates/tty7-core/src/daemon/protocol.rs @@ -531,7 +531,6 @@ pub enum SshTestNeed { } impl NativeSshSpec { - #[allow(dead_code)] pub fn without_secrets(&self) -> NativeSshSpec { NativeSshSpec { password: None, diff --git a/crates/tty7-core/src/daemon/ssh/session.rs b/crates/tty7-core/src/daemon/ssh/session.rs index 4855442f..ee70c78a 100644 --- a/crates/tty7-core/src/daemon/ssh/session.rs +++ b/crates/tty7-core/src/daemon/ssh/session.rs @@ -160,7 +160,6 @@ pub async fn drive_channel( pub struct SshConnection { handle: tokio::sync::Mutex>, - #[allow(dead_code)] key: ConnectionKey, remote_forwards: RemoteForwardTable, alive: AtomicBool, @@ -182,7 +181,6 @@ impl SshConnection { }) } - #[allow(dead_code)] pub fn key(&self) -> &ConnectionKey { &self.key } diff --git a/src/core/ssh_config.rs b/src/core/ssh_config.rs index fec3b576..c76644ca 100644 --- a/src/core/ssh_config.rs +++ b/src/core/ssh_config.rs @@ -202,7 +202,6 @@ pub struct ImportReport { pub files_read: usize, } -#[allow(dead_code)] pub fn import_profiles() -> Vec { let Some(home) = home_dir() else { return Vec::new(); @@ -424,7 +423,6 @@ pub struct MergeStats { pub unchanged: usize, } -#[allow(dead_code)] pub fn merge_imported( existing: &mut Vec, imported: Vec, @@ -486,7 +484,6 @@ pub fn merge_imported( stats } -#[allow(dead_code)] fn jump_alias(raw: &str) -> Option { let first = raw.split(',').next().unwrap_or(raw).trim(); if first.is_empty() { diff --git a/src/terminal/cmd_editor.rs b/src/terminal/cmd_editor.rs index 69f795c2..b8e5ec15 100644 --- a/src/terminal/cmd_editor.rs +++ b/src/terminal/cmd_editor.rs @@ -27,12 +27,11 @@ impl CmdEditor { self.chars.len() } - #[allow(dead_code)] pub fn cursor(&self) -> usize { self.cursor } - #[allow(dead_code)] + #[cfg_attr(not(test), allow(dead_code))] pub fn cursor_byte(&self) -> usize { self.chars[..self.cursor].iter().map(|c| c.len_utf8()).sum() }