diff --git a/src/terminal.rs b/src/terminal.rs index 699cf1a..e4c4ed7 100644 --- a/src/terminal.rs +++ b/src/terminal.rs @@ -415,12 +415,13 @@ impl Terminal { } pub fn working_directory(&self) -> Option { - #[cfg(not(windows))] + #[cfg(target_os = "linux")] { let shell_pid = self.shell_pid?; fs::read_link(format!("/proc/{shell_pid}/cwd")).ok() } - #[cfg(windows)] + + #[cfg(not(target_os = "linux"))] { None }