Skip to content

Commit 23cbfef

Browse files
committed
Don't assume that gcloud is in the same place as gsutil.
1 parent e0d44f7 commit 23cbfef

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

lib/common.sh

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -946,8 +946,9 @@ common::set_cloud_binaries () {
946946
[[ -x $GSUTIL ]] && break
947947
done
948948

949-
# gcloud should be in the same place
950-
GCLOUD=${GSUTIL/gsutil/gcloud}
949+
for GCLOUD in "$GSUTIL/gsutil/gcloud" "$(which gcloud)"; do
950+
[[ -x $GCLOUD ]] && break
951+
done
951952

952953
if [[ -x "$GSUTIL" && -x "$GCLOUD" ]]; then
953954
logecho -r $OK

0 commit comments

Comments
 (0)