Can I use gcloud in Git Bash on Windows?

ensminger picture ensminger · Apr 25, 2016 · Viewed 8.9k times · Source

So, I've installed Git, Git Bash, Python2.7, and I've just installed the Google Cloud SDK per the official guide. Using Windows 10.

In cmd.exe, or the "Google Cloud SDK Shell", gcloud works fine.

Within Git Bash, however (the terminal that I prefer to use), gcloud returns the following output (screenshot).

enter image description here

echo $PATH in Git Bash does include the path to the Google SDK (highlighted here).

enter image description here

Am I missing something? Is there anything in $PATH that is possibly conflicting with gcloud, or did I misconfigure the path somehow?

I appreciate any insight.


UPDATE. Here is the output of env|grep PATH. I'm not sure what it tells me. Any other executable in the PATH is working (vagrant, conda, python, etc), but gcloud is not.

enter image description here

Answer

Vilas picture Vilas · Apr 25, 2016

You need to use the full file name i.e. gcloud.sh or gcloud.cmd. See the following question for more details:

Git Bash doesn't see my PATH