Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Android Studio: Can't start Git

When I start Android Studio there's a message

Can't start Git: C:\Program Files (x86)\Git\cmd\git.cmd Probably the path to Git executable is not valid. Fix it.

But I can see that the git.cmd IS there. How do I fix the issue then?

like image 914
Alexander Kulyakhtin Avatar asked Jun 09 '13 07:06

Alexander Kulyakhtin


People also ask

Does Android studio work with git?

With Android Studio, you don't need to use the terminal to contribute to an Android project on GitHub. It has native integration with git and GitHub to allow most actions via the Android Studio UI.

How do I know if git is installed on Android studio?

So, to do this we are going to click on “File” and then on “Settings”. Now, in Settings, we are going to click on “Version Control” and then “Git”, and in the top portion, it is said that “Auto Detected” is the path where the Git executable file is, and on clicking on “Test” the Git Version which is installed is shown.

Can not run git in IntelliJ?

go to the terminal and type git --exec-path to get your git path. then go to IntelliJ and configure it, Click browse and select your git path. select git and hit test.


2 Answers

For some reason this morning, I had to agree to the terms and conditions by running git as administrator in the command line.

On the mac

sudo /usr/bin/git

On the pc

c:\path\to\git.exe

Accept the EULA.

After I did that, I was able to use git in my IDE.

like image 82
tyler Avatar answered Sep 20 '22 13:09

tyler


For the one using mac who installed Xcode7, you have to start Xcode and accept the license agreement for the android studio error to go away.

like image 37
Distwo Avatar answered Sep 20 '22 13:09

Distwo