6533dc6b41af2661e555b1d0bd340e9ea3d63785
- Author
- Robby Russell <robby@planetargon.com>
- Committer
- Robby Russell <robby@planetargon.com>
- Date
Message
Merge pull request #2184 from jmagnusson/agnoster_respect_venv_disable_prompt
Fix: Agnoster theme doesn't respect VIRTUAL_ENV_DISABLE_PROMPT
Diff
1diff --git a/themes/agnoster.zsh-theme b/themes/agnoster.zsh-theme
2index c7a59ad0d67951960f1a9edb4544bd1da6aa849e..3ad4eff1f256653e43f5bd8668c28e8eec0c95e5 100644
3--- a/themes/agnoster.zsh-theme
4+++ b/themes/agnoster.zsh-theme
5@@ -137,7 +137,7 @@ prompt_dir() {
6 # Virtualenv: current working virtualenv
7 prompt_virtualenv() {
8 local virtualenv_path="$VIRTUAL_ENV"
9- if [[ -n $virtualenv_path ]]; then
10+ if [[ -n $virtualenv_path && -z $VIRTUAL_ENV_DISABLE_PROMPT ]]; then
11 prompt_segment blue black "(`basename $virtualenv_path`)"
12 fi
13 }