diff --git a/mux/src/localpane.rs b/mux/src/localpane.rs index 53f12e232..546e5547e 100644 --- a/mux/src/localpane.rs +++ b/mux/src/localpane.rs @@ -270,7 +270,19 @@ impl Pane for LocalPane { } fn get_title(&self) -> String { - self.terminal.borrow_mut().get_title().to_string() + let title = self.terminal.borrow_mut().get_title().to_string(); + // If the title is the default pane title, then try to spice + // things up a bit by returning the process basename instead + if title == "wezterm" { + if let Some(proc_name) = self.get_foreground_process_name() { + let proc_name = std::path::Path::new(&proc_name); + if let Some(name) = proc_name.file_name() { + return name.to_string_lossy().to_string(); + } + } + } + + title } fn palette(&self) -> ColorPalette {