diff options
Diffstat (limited to 'src/app/creation.rs')
| -rw-r--r-- | src/app/creation.rs | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/src/app/creation.rs b/src/app/creation.rs index 7be324e5..a45dae03 100644 --- a/src/app/creation.rs +++ b/src/app/creation.rs @@ -112,6 +112,7 @@ impl App { self.state.pane_scrollback_limit_bytes, self.state.host_terminal_theme, crate::pane::PaneShellConfig::new(&self.state.default_shell, self.state.shell_mode), + Vec::new(), )?; let root_pane = ws.tabs[idx].root_pane; self.terminal_runtimes.insert(terminal.id.clone(), runtime); @@ -140,8 +141,17 @@ impl App { initial_cwd: PathBuf, focus: bool, ) -> std::io::Result<usize> { + self.create_workspace_with_launch_env(initial_cwd, focus, Vec::new()) + } + + pub(crate) fn create_workspace_with_launch_env( + &mut self, + initial_cwd: PathBuf, + focus: bool, + extra_env: Vec<(String, String)>, + ) -> std::io::Result<usize> { let (rows, cols) = self.state.estimate_pane_size(); - let (ws, terminal, runtime) = Workspace::new( + let (ws, terminal, runtime) = Workspace::new_with_extra_env( initial_cwd, rows, cols, @@ -151,6 +161,7 @@ impl App { self.event_tx.clone(), self.render_notify.clone(), self.render_dirty.clone(), + extra_env, )?; self.terminal_runtimes.insert(terminal.id.clone(), runtime); self.state.terminals.insert(terminal.id.clone(), terminal); |
