diff options
Diffstat (limited to 'zellij-server/src/pty.rs')
-rw-r--r-- | zellij-server/src/pty.rs | 15 |
1 files changed, 13 insertions, 2 deletions
diff --git a/zellij-server/src/pty.rs b/zellij-server/src/pty.rs index fd67234c3..4c4f0a910 100644 --- a/zellij-server/src/pty.rs +++ b/zellij-server/src/pty.rs @@ -147,6 +147,7 @@ pub(crate) fn pty_thread_main(mut pty: Pty, layout: Box<Layout>) -> Result<()> { pty.bus.senders.clone(), *terminal_id, run_command.clone(), + None, ) .with_context(err_context)?; } @@ -243,6 +244,7 @@ pub(crate) fn pty_thread_main(mut pty: Pty, layout: Box<Layout>) -> Result<()> { Some(2), // exit status run_command, None, + None, )) .with_context(err_context)?; } @@ -313,6 +315,7 @@ pub(crate) fn pty_thread_main(mut pty: Pty, layout: Box<Layout>) -> Result<()> { Some(2), // exit status run_command, None, + None, )) .with_context(err_context)?; } @@ -422,6 +425,7 @@ pub(crate) fn pty_thread_main(mut pty: Pty, layout: Box<Layout>) -> Result<()> { Some(2), // exit status run_command, None, + None, )) .with_context(err_context)?; } @@ -532,6 +536,7 @@ impl Pty { exit_status, command, None, + None, )); } else { let _ = senders.send_to_screen(ScreenInstruction::ClosePane(pane_id, None)); @@ -599,14 +604,14 @@ impl Pty { // new_pane_pids for run_instruction in extracted_run_instructions { if let Some(new_pane_data) = - self.apply_run_instruction(run_instruction, default_shell.clone())? + self.apply_run_instruction(run_instruction, default_shell.clone(), tab_index)? { new_pane_pids.push(new_pane_data); } } for run_instruction in extracted_floating_run_instructions { if let Some(new_pane_data) = - self.apply_run_instruction(run_instruction, default_shell.clone())? + self.apply_run_instruction(run_instruction, default_shell.clone(), tab_index)? { new_floating_panes_pids.push(new_pane_data); } @@ -686,6 +691,7 @@ impl Pty { self.bus.senders.clone(), terminal_id, run_command.clone(), + Some(tab_index), ) .with_context(err_context)?; } else { @@ -706,6 +712,7 @@ impl Pty { &mut self, run_instruction: Option<Run>, default_shell: TerminalAction, + tab_index: usize, ) -> Result<Option<(u32, bool, Option<RunCommand>, Result<i32>)>> { // terminal_id, // starts_held, @@ -730,6 +737,7 @@ impl Pty { pane_id, exit_status, command, + Some(tab_index), None, )); } else { @@ -935,6 +943,7 @@ impl Pty { exit_status, command, None, + None, )); } else { let _ = @@ -996,6 +1005,7 @@ fn send_command_not_found_to_screen( senders: ThreadSenders, terminal_id: u32, run_command: RunCommand, + tab_index: Option<usize>, ) -> Result<()> { let err_context = || format!("failed to send command_not_fount for terminal {terminal_id}"); senders @@ -1011,6 +1021,7 @@ fn send_command_not_found_to_screen( PaneId::Terminal(terminal_id), Some(2), run_command.clone(), + tab_index, None, )) .with_context(err_context)?; |