diff --git a/scripts/env.sh b/scripts/env.sh index 9e9b2d1..d2298ff 100755 --- a/scripts/env.sh +++ b/scripts/env.sh @@ -68,12 +68,14 @@ $EXPORT_FUNC add_submodule export NIMBUS_BUILD_SYSTEM=yes -if [[ $# == 1 && $1 == "bash" ]]; then - # the only way to change PS1 in a child shell, apparently - # (we're not getting the original PS1 value in here, so set a complete and nice prompt) - export PS1="[Nimbus env] \[\033[0;31m\]\l \[\033[1;33m\]\d \[\033[1;36m\]\t \[\033[0;32m\]|\w|\[\033[0m\]\n\u\$ " - exec "$1" --login --noprofile -else - # can't use "exec" here if we're getting function names as params - "$@" +if [[ ! -n "$NBS_ONLY_LOAD_ENV_VARS" ]]; then + if [[ $# == 1 && $1 == "bash" ]]; then + # the only way to change PS1 in a child shell, apparently + # (we're not getting the original PS1 value in here, so set a complete and nice prompt) + export PS1="[Nimbus env] \[\033[0;31m\]\l \[\033[1;33m\]\d \[\033[1;36m\]\t \[\033[0;32m\]|\w|\[\033[0m\]\n\u\$ " + exec "$1" --login --noprofile + else + # can't use "exec" here if we're getting function names as params + "$@" + fi fi