Browse Source

fix(gcloud): source `path.zsh.inc` always (#11901)

Marc-Antoine Godde 8 months ago
parent
commit
91cd5341b9
1 changed files with 3 additions and 5 deletions
  1. 3 5
      plugins/gcloud/gcloud.plugin.zsh

+ 3 - 5
plugins/gcloud/gcloud.plugin.zsh

@@ -29,11 +29,9 @@ if [[ -z "${CLOUDSDK_HOME}" ]]; then
 fi
 
 if (( ${+CLOUDSDK_HOME} )); then
-  # Only source this if gcloud isn't already on the path
-  if (( ! $+commands[gcloud] )); then
-    if [[ -f "${CLOUDSDK_HOME}/path.zsh.inc" ]]; then
-      source "${CLOUDSDK_HOME}/path.zsh.inc"
-    fi
+  # Source path file
+  if [[ -f "${CLOUDSDK_HOME}/path.zsh.inc" ]]; then
+    source "${CLOUDSDK_HOME}/path.zsh.inc"
   fi
 
   # Look for completion file in different paths