diff options
| author | Daiderd Jordan <daiderd@gmail.com> | 2018-01-13 14:51:36 +0100 |
|---|---|---|
| committer | Daiderd Jordan <daiderd@gmail.com> | 2018-01-13 14:51:36 +0100 |
| commit | ed72bf64097b177ee734a604be37595322654acd (patch) | |
| tree | f63207b0f18013103a85228901543e06ff41ffb9 /modules/programs/bash.nix | |
| parent | bf7212817713995128f455ced2ac4d8cd80ccaba (diff) | |
bash: don't setup environment in a nix-shell
Diffstat (limited to 'modules/programs/bash.nix')
| -rw-r--r-- | modules/programs/bash.nix | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/modules/programs/bash.nix b/modules/programs/bash.nix index dc58af4..ee13377 100644 --- a/modules/programs/bash.nix +++ b/modules/programs/bash.nix @@ -72,6 +72,9 @@ in if [ -n "$__ETC_BASHRC_SOURCED" -o -n "$NOSYSBASHRC" ]; then return; fi __ETC_BASHRC_SOURCED=1 + # Don't execute this file when running in a pure nix-shell. + if test -n "$IN_NIX_SHELL"; then return; fi + export PATH=${config.environment.systemPath} ${config.system.build.setEnvironment.text} ${config.system.build.setAliases.text} |
