I am on a mac and am trying to install the Google Cloud SDK (including the gcloud command line utility) using this command in terminal
curl https://sdk.cloud
If you are on MAC OS and using .zsh shell then do the following:
Edit your .zshrc and add the following
# The next line updates PATH for the Google Cloud SDK.
source /Users/USER_NAME/google-cloud-sdk/path.zsh.inc
# The next line enables zsh completion for gcloud.
source /Users/USER_NAME/google-cloud-sdk/completion.zsh.inc
Create new file named path.zsh.inc under your home directory(/Users/USER_NAME/):
script_link="$( readlink "$0" )" || script_link="$0"
apparent_sdk_dir="${script_link%/*}"
if [ "$apparent_sdk_dir" == "$script_link" ]; then
apparent_sdk_dir=.
fi
sdk_dir="$( cd -P "$apparent_sdk_dir" && pwd -P )"
bin_path="$sdk_dir/bin"
export PATH=$bin_path:$PATH
Checkout more @ Official Docs