- bash: git: command not found in Xcode 4 in lion osx

Via Xcode 4.3 -> file -> source control -> repositories -> clone repository, I cloned the repository from codeion.com. but when I go to git init or git add, an error appears - bash: git: command not found. Xcode 4.3 now comes with git installed, so what should I do to get this to work?

Any help on this would be great.

Thanks in advance.

+6
source share
2 answers

This is a problem of the way. Answer this question:

How to move GCC to osx from xcode to / usr / bin

(PS The question is different, but the answer is the same.)

+2
source

There is another option if you are not familiar with UNIX or simply do not want to bind to system variables from the terminal. I had the same problem, and after some reading on the SO and apple developer pages, I decided to install the Command Line Tools for Xcode . This solved the problem.

Since the Xcode IDE from version 4.x is an .app package, and everything is stored inside this package, they added the ability to separately install command line tools so that you have command line tools inside usr / bin / path.

You can install the command line tools (as well as some other tools and documentation) on the Downloads tab of the Preferences window in Xcode (I have version 4.3) or on the Apple developer website.

+8
source

Source: https://habr.com/ru/post/912004/


All Articles