The "git" Command Requires The Command Line Developer Tools. Would You Like To Install?
Solution 1:
There are three main sources for Git on macOS.
The first is Apple, using the command line developer tools. These tools install a standard set of Unix development tools, including a compiler and Git. While this is called the XCode development tools, it is significantly smaller than the full IDE XCode environment.
The second is Homebrew, which is commonly used for this purpose. It's going to be the most up to date. This also requires the command line developer tools.
The third is the download page from the Git website. This is maintained by a third party, not the Git maintainers, and isn't always up to date, but it's usually only a few versions behind.
The last option is to compile from source, but that requires a compiler, which generally requires the command line developer tools.
Barring other package managers like Fink, there are no other reputable sources for Git packages on macOS. You'll have to pick one of the options above if you want to use Git.
Solution 2:
I encountered the same issue when I was going to use Git on a new macOS. My solution is pretty simple, but just to install homebrew
.
The trick is that homebrew
install loads a git repo of full source history. To achieve this, it firstly installs XCode
command line development tool to get Git.
Then, after you have homebrew
, you can benefit from XCode
tools to issue git
commands. Note that no need to install other parts of XCode
here.
I was also surprised to see what happened at homebrew
install. There might be a reason from homebrew
developers.
Post a Comment for "The "git" Command Requires The Command Line Developer Tools. Would You Like To Install?"