diff --git a/src/daemon/server.rs b/src/daemon/server.rs index a1c8895a..96749f5b 100644 --- a/src/daemon/server.rs +++ b/src/daemon/server.rs @@ -24,7 +24,7 @@ use std::sync::mpsc::{self, Receiver}; use std::sync::{Arc, Mutex}; use crate::daemon::pane::DaemonPane; -use crate::daemon::protocol::{ClientMsg, DaemonMsg, DaemonVersion, RemoteKind, PROTOCOL_VERSION}; +use crate::daemon::protocol::{ClientMsg, DaemonMsg, DaemonVersion, PROTOCOL_VERSION, RemoteKind}; use crate::daemon::ssh::SshConnection; use crate::daemon::transport::{self, Stream}; diff --git a/src/daemon/spawn.rs b/src/daemon/spawn.rs index c768b296..d71fe63f 100644 --- a/src/daemon/spawn.rs +++ b/src/daemon/spawn.rs @@ -58,8 +58,7 @@ pub struct MismatchedDaemon { pub version: Option, } -static MISMATCHED_DAEMON: std::sync::Mutex> = - std::sync::Mutex::new(None); +static MISMATCHED_DAEMON: std::sync::Mutex> = std::sync::Mutex::new(None); /// The protocol mismatch recorded by [`ensure_running`] this launch, if any. /// Take-semantics so the prompt fires once per launch, not per window. @@ -187,7 +186,12 @@ fn query_daemon_version(stream: &mut transport::Stream) -> VersionProbe { } match DaemonMsg::read(stream) { Ok(DaemonMsg::Version(v)) => VersionProbe::Speaks(v), - Err(e) if matches!(e.kind(), io::ErrorKind::TimedOut | io::ErrorKind::WouldBlock) => { + Err(e) + if matches!( + e.kind(), + io::ErrorKind::TimedOut | io::ErrorKind::WouldBlock + ) => + { VersionProbe::Unresponsive } // EOF/reset (the pre-versioning hangup) — and, conservatively, any diff --git a/src/terminal/view.rs b/src/terminal/view.rs index 74c90909..7632b14f 100644 --- a/src/terminal/view.rs +++ b/src/terminal/view.rs @@ -2488,8 +2488,9 @@ impl TerminalView { // Landing through `update_global` wakes the sidebar's // `observe_global`, so every pane in the repo repaints — not // just this one. - let rerun = cx - .update_global::(|cache, _| cache.finish_probe(&cwd, result)); + let rerun = cx.update_global::(|cache, _| { + cache.finish_probe(&cwd, result) + }); // A trigger arrived while we flew; go once more so its state // is observed — unless this pane has since left that cwd. if rerun && view.git_status_cwd.as_deref() == Some(&cwd) { diff --git a/src/ui/app.rs b/src/ui/app.rs index 17004b3d..ec35ffe2 100644 --- a/src/ui/app.rs +++ b/src/ui/app.rs @@ -446,8 +446,8 @@ impl Tty7App { // sidebar's branch/diff lines read from it, and the probing pane's own // notify wouldn't re-render rows belonging to *other* panes. cx.default_global::(); - let git_status_watch = cx - .observe_global::(|_, cx| cx.notify()); + let git_status_watch = + cx.observe_global::(|_, cx| cx.notify()); // Any real keypress means "chord, not a bare hold": cancel the held-⌘ // tab badges and whatever reveal is pending (see `ui::hints`). let this = cx.weak_entity(); @@ -2867,7 +2867,7 @@ impl Tty7App { } else { match phase { SshPhase::Connecting | SshPhase::Authenticating => 0xF59E0B, // amber: in flight - SshPhase::Connected => 0x22C55E, // green: link up + SshPhase::Connected => 0x22C55E, // green: link up SshPhase::Failed { .. } => 0xEF4444, // red: never made it } }; diff --git a/src/ui/tab_strip.rs b/src/ui/tab_strip.rs index ed7e735f..c8ff4a35 100644 --- a/src/ui/tab_strip.rs +++ b/src/ui/tab_strip.rs @@ -269,7 +269,9 @@ impl Tty7App { // SSH connection phase as a corner status dot — the same // element as an agent's, not a border ring around the badge // (a ring read as a second, differently-shaped avatar style). - .when_some(ssh, |b, rgb| b.child(Self::status_dot(rgb, false, size, cx))) + .when_some(ssh, |b, rgb| { + b.child(Self::status_dot(rgb, false, size, cx)) + }) .into_any_element(), } }