acp_thread: Respect terminal settings shell for terminal tool environment (#39349)
When sourcing the project environment for the terminal tool, we will now do so by spawning the shell specified by the users `terminal.shell` setting (or as usual fall back to the login shell). Closes #37687 Release Notes: - N/A
This commit is contained in:
@@ -1187,11 +1187,13 @@ impl ToolchainLister for PythonToolchainProvider {
|
||||
ShellKind::PowerShell => ".",
|
||||
ShellKind::Fish => "source",
|
||||
ShellKind::Csh => "source",
|
||||
ShellKind::Posix => "source",
|
||||
ShellKind::Tcsh => "source",
|
||||
ShellKind::Posix | ShellKind::Rc => "source",
|
||||
};
|
||||
let activate_script_name = match shell {
|
||||
ShellKind::Posix => "activate",
|
||||
ShellKind::Posix | ShellKind::Rc => "activate",
|
||||
ShellKind::Csh => "activate.csh",
|
||||
ShellKind::Tcsh => "activate.csh",
|
||||
ShellKind::Fish => "activate.fish",
|
||||
ShellKind::Nushell => "activate.nu",
|
||||
ShellKind::PowerShell => "activate.ps1",
|
||||
@@ -1220,7 +1222,9 @@ impl ToolchainLister for PythonToolchainProvider {
|
||||
ShellKind::Nushell => Some(format!("\"{pyenv}\" shell - nu {version}")),
|
||||
ShellKind::PowerShell => None,
|
||||
ShellKind::Csh => None,
|
||||
ShellKind::Tcsh => None,
|
||||
ShellKind::Cmd => None,
|
||||
ShellKind::Rc => None,
|
||||
})
|
||||
}
|
||||
_ => {}
|
||||
|
||||
Reference in New Issue
Block a user