Make Xcode 4 auto-stop with git

I hate that whenever I make changes to Xcode 4, it automatically executes the “Git add” command. Is there any way to make this stop?

+8
git xcode xcode4
source share
5 answers

Not. Xcode 4 git integration is “broken” by trying to present a single interface for source control, whether it is back-end git or svn. This means that they only support the lowest common denominator of functionality. As a result, the use of an index (“intermediate region”) is absent. It always makes automatic additions whether you want it or not.

EDIT: Actually, I don't think this automatically adds. I think he is always commit -a . Looking at git status on the command line, I see a lot of new and changed files that are NOT delivered. But I'm sure that if I committed to Xcode, they would all end this commit.

+8
source share

What I'm doing is doing all my git interaction through the command line. Since I cannot force Xcode to ignore the fact that my project is under git control, and since I cannot force Xcode to stop git add for each new file that I create, when I get to the command line the first thing I do is this is a git reset to reset index. This destroys all the annoying git add things that Xcode did automatically. Now I am responsible for what is included in the index, and therefore I can form my own commits the way I want.

+7
source share

For Xcode 6, this is no longer a problem. Go to the "Settings" tab → "Source Control" and uncheck the box "Add and delete files automatically"

+4
source share

For me, the solution was as follows: https://stackoverflow.com/a/166268/

TL; DR; remove repository from xcode organizer

+3
source share

While the question title says Xcode 4, this question appears at the top for many search results related to this problem, even in newer versions of Xcode. Here is the answer for newer versions of Xcode. In Xcode 6, you can turn off version control by going to Xcode → Settings → the Source Control tab and uncheck the Enable Source Control box.

+1
source share

All Articles