From e0758c32118f2aa006db3d8fa4b41833fe6e7ead Mon Sep 17 00:00:00 2001 From: Ogulcan Celik Date: Fri, 17 Jul 2026 23:55:08 +0300 Subject: feat: harden named agent cli workflows refs #1525 --- src/platform/linux.rs | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'src/platform/linux.rs') diff --git a/src/platform/linux.rs b/src/platform/linux.rs index 48f1ef1c..6557b41b 100644 --- a/src/platform/linux.rs +++ b/src/platform/linux.rs @@ -70,6 +70,10 @@ pub(crate) fn scrollback_editor_argv(path: &std::path::Path) -> std::io::Result< Ok(vec!["/bin/sh".to_string(), "-c".to_string(), command]) } +pub(crate) fn interactive_shell_command(argv: &[String], shell_name: &str) -> Option { + super::interactive_unix_shell_command(argv, shell_name, shell_quote) +} + fn shell_quote(value: &str) -> String { if !value.is_empty() && value.chars().all(|ch| { @@ -87,6 +91,10 @@ fn shell_quote(value: &str) -> String { } /// Collect the foreground terminal job for a given child PID. +pub(crate) fn available_pane_shell(child_pid: u32) -> Option { + super::available_pane_shell_from_job(child_pid, foreground_job(child_pid)?) +} + pub fn foreground_job(child_pid: u32) -> Option { let tpgid = foreground_process_group_id(child_pid)?; let members = foreground_process_group_members(child_pid, tpgid)?; -- cgit v1.2.3