We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 3ce6209 commit ea484a4Copy full SHA for ea484a4
utils/src/shell_wrapper.rs
@@ -18,7 +18,10 @@ fn real_main() -> anyhow::Result<()> {
18
let shell = read_link(exe_dir.join("shell")).context("when locating the wrapped shell")?;
19
20
// Set the SHELL environment variable to the wrapped shell instead of the wrapper
21
- env::set_var("SHELL", &shell);
+ let shell_env = env::var_os("SHELL").unwrap_or_default();
22
+ if shell_env == exe {
23
+ env::set_var("SHELL", &shell);
24
+ }
25
26
// Skip if environment was already set
27
if env::var_os("__NIXOS_SET_ENVIRONMENT_DONE") != Some("1".into()) {
0 commit comments