diff options
| author | Ogulcan Celik <ogulcancelik@gmail.com> | 2026-05-20 00:29:53 +0300 |
|---|---|---|
| committer | Ogulcan Celik <ogulcancelik@gmail.com> | 2026-05-20 00:34:27 +0300 |
| commit | 2b97799b6715fd6c355db9c225029765971915e6 (patch) | |
| tree | cb7c2c7093f439ad3460687b88c3e6cf539b64e8 /src/workspace.rs | |
| parent | ff8e5a14abe445a61dc200fd30a70870c75d183c (diff) | |
feat: add configurable default shell
refs #196
Diffstat (limited to 'src/workspace.rs')
| -rw-r--r-- | src/workspace.rs | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/src/workspace.rs b/src/workspace.rs index 69a83d75..47fa9cf7 100644 --- a/src/workspace.rs +++ b/src/workspace.rs @@ -89,6 +89,7 @@ impl Workspace { cols: u16, scrollback_limit_bytes: usize, host_terminal_theme: crate::terminal_theme::TerminalTheme, + default_shell: &str, events: mpsc::Sender<AppEvent>, render_notify: Arc<Notify>, render_dirty: Arc<AtomicBool>, @@ -99,6 +100,7 @@ impl Workspace { cols, scrollback_limit_bytes, host_terminal_theme, + default_shell, events, render_notify, render_dirty, @@ -123,6 +125,7 @@ impl Workspace { cols, scrollback_limit_bytes, host_terminal_theme, + "", events, render_notify, render_dirty, @@ -137,6 +140,7 @@ impl Workspace { cols: u16, scrollback_limit_bytes: usize, host_terminal_theme: crate::terminal_theme::TerminalTheme, + default_shell: &str, events: mpsc::Sender<AppEvent>, render_notify: Arc<Notify>, render_dirty: Arc<AtomicBool>, @@ -163,6 +167,7 @@ impl Workspace { cols, scrollback_limit_bytes, host_terminal_theme, + default_shell, events, render_notify, render_dirty, @@ -223,6 +228,7 @@ impl Workspace { cwd: PathBuf, scrollback_limit_bytes: usize, host_terminal_theme: crate::terminal_theme::TerminalTheme, + default_shell: &str, ) -> std::io::Result<(usize, TerminalState, TerminalRuntime)> { self.create_tab_with_runtime( rows, @@ -230,6 +236,7 @@ impl Workspace { cwd, scrollback_limit_bytes, host_terminal_theme, + default_shell, None, ) } @@ -241,6 +248,7 @@ impl Workspace { cwd: PathBuf, scrollback_limit_bytes: usize, host_terminal_theme: crate::terminal_theme::TerminalTheme, + default_shell: &str, argv: Option<&[String]>, ) -> std::io::Result<(usize, TerminalState, TerminalRuntime)> { let number = self.tabs.len() + 1; @@ -278,6 +286,7 @@ impl Workspace { cols, scrollback_limit_bytes, host_terminal_theme, + default_shell, events, render_notify, render_dirty, @@ -343,6 +352,7 @@ impl Workspace { cwd: Option<PathBuf>, scrollback_limit_bytes: usize, host_terminal_theme: crate::terminal_theme::TerminalTheme, + default_shell: &str, ) -> std::io::Result<crate::workspace::tab::NewPane> { let new_pane = self .active_tab_mut() @@ -354,6 +364,7 @@ impl Workspace { cwd, scrollback_limit_bytes, host_terminal_theme, + default_shell, )?; self.register_new_pane(new_pane.pane_id); Ok(new_pane) @@ -368,6 +379,7 @@ impl Workspace { cwd: Option<PathBuf>, scrollback_limit_bytes: usize, host_terminal_theme: crate::terminal_theme::TerminalTheme, + default_shell: &str, focus_new_pane: bool, ) -> Option<std::io::Result<(usize, crate::workspace::tab::NewPane)>> { self.split_pane_with_runtime( @@ -378,6 +390,7 @@ impl Workspace { cwd, scrollback_limit_bytes, host_terminal_theme, + default_shell, focus_new_pane, None, ) @@ -404,6 +417,7 @@ impl Workspace { cwd, scrollback_limit_bytes, host_terminal_theme, + "", focus_new_pane, Some(argv), ) @@ -419,6 +433,7 @@ impl Workspace { cwd: Option<PathBuf>, scrollback_limit_bytes: usize, host_terminal_theme: crate::terminal_theme::TerminalTheme, + default_shell: &str, focus_new_pane: bool, argv: Option<&[String]>, ) -> Option<std::io::Result<(usize, crate::workspace::tab::NewPane)>> { @@ -444,6 +459,7 @@ impl Workspace { cwd, scrollback_limit_bytes, host_terminal_theme, + default_shell, ) } { Ok(new_pane) => new_pane, |
