Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

does git for windows run the git executable in the cmd or the bin directory?

Richard Anderson
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
February 26, 2018

I successfully upgraded/installed git for windows, but was surprised to see git executables in both the bin and cmd directories in C:\Program Files\Git.  Which one is used?  Why are these executables in both locations?

1 answer

1 vote
Dave Chevell
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
April 8, 2018

To see which executable is being used (in any situation, not just this one), you can use the where command. It's the equivalent to Linux's which command that does the same thing:

where git

This should print the path to the git executable that is used whenever you call git from the command line.

As for why there are executables in both locations, it's hard to say without knowing more about how you installed git. Are both of those executables valid git binaries? If you call the fill path to them (e.g. "C:\Program Files\Git\cmd\git.exe" --version) does it work?

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events