Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Windows- Can't start Git: Probably the path to Git executable is not valid

Can't start Git: C:\Users\Cloudion PC\AppData\Local\GitHub\PortableGit_d93ee8917cfa9add886773e6be9ec08609a502b6\bin\git.exe Probably the path to Git executable is not valid.

I am getting the above message which is related to the git in android studio for windows.so far I am using android studio without any problem for last couple of months. now I am getting this all the time I type the code.

`C:\Users\Cloudion\AppData\Local\GitHub\PortableGit_d93ee8917cfa9add886773e6be9ec08609a502b6\bin\git.exe`

but now I cant find git.exe at the above. What happened? Does the location change?

like image 623
Nabeel K Avatar asked Nov 26 '15 13:11

Nabeel K


People also ask

Where is git EXE located in Windows?

The default path on windows is C:\Program Files (x86)\Git .

Where is git path in VS code?

Open setting. json(or File>Preferences>Settings). Navigate to Workspace Settings. Find "Path" and add paths to Git bin and cmd folders.

How do I download git for Windows?

Install Git on WindowsNavigate to the latest Git for Windows installer and download the latest version. Once the installer has started, follow the instructions as provided in the Git Setup wizard screen until the installation is complete.


2 Answers

Type which git in your terminal/cmd (find out the git path)

which git

It will give you the original path, where it is installed. Then pass/set that path in your android studio and then click test button. It will be shown success.

My mistake was, previously I had a path like /usr/bin/git It doesn't work. Then

which git

It gave the correct path. /usr/local/bin/git

FYI, I'm using Mac

like image 100
Praveen Kumar Sugumaran Avatar answered Sep 28 '22 08:09

Praveen Kumar Sugumaran


After installing GitHubDesktop: https://desktop.github.com/, depending on your version, the location looks like:

C:\Users\YOUR-USER-NAME\AppData\Local\GitHubDesktop\app-0.5.3\resources\app\git\mingw64\bin\git.exe

In the Android Studio event console you can click on +Fix it+ link, right after Can't start Git: git.exe Probably the path to Git executable is not valid. message. This brings you to the setting window to enter the full path to the git.exe

like image 25
epox Avatar answered Sep 28 '22 09:09

epox