diff options
author | Tristan Escalada <tristan@escalada.us> | 2018-10-05 14:56:56 -0400 |
---|---|---|
committer | Marc Cornellà <marc.cornella@live.com> | 2018-10-05 20:56:56 +0200 |
commit | 9e14387408fd83be63ac5158f4671944ca9bad14 (patch) | |
tree | 32478a1b95385a54e0c78e1fef566255515ed7c5 | |
parent | e09eb23158c7c75b84b7dafb514dcfa86bd06dc3 (diff) | |
download | zsh-9e14387408fd83be63ac5158f4671944ca9bad14.tar.gz zsh-9e14387408fd83be63ac5158f4671944ca9bad14.tar.bz2 zsh-9e14387408fd83be63ac5158f4671944ca9bad14.zip |
terraform: disable terraform prompt in $HOME (#7227)
In the home directory there is a .terraform folder for modules but it is most likely not
an actual directory of terraform scripts. Therefore, this patch disables checking for workspace in the home directory.
-rw-r--r-- | plugins/terraform/terraform.plugin.zsh | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/plugins/terraform/terraform.plugin.zsh b/plugins/terraform/terraform.plugin.zsh index b170f73a6..d727c1ee0 100644 --- a/plugins/terraform/terraform.plugin.zsh +++ b/plugins/terraform/terraform.plugin.zsh @@ -1,4 +1,6 @@ function tf_prompt_info() { + # dont show 'default' workspace in home dir + [[ "$PWD" == ~ ]] && return # check if in terraform dir if [ -d .terraform ]; then workspace=$(terraform workspace show 2> /dev/null) || return |