xcodegitbitbucketatlassian-sourcetreexcode-project

Git not able to recognise addition of .xcscheme files in xcode project


Added a new scheme corresponding to a test target in my xcode project. The new xcscheme file created is not getting reflected in git. Also doing a git status shows me nothing to commit, working directory clean .

Trying to add it through terminal by git add .xcscheme says

The following paths are ignored by one of your .gitignore files: MyProject.xcodeproj/xcshareddata/xcschemes/MyProjectTests.xcscheme Use -f if you really want to add them

On verifying my .gitignore file, its completely blank.

I went through posts which asks to make the schemes shared but it did not help. Went through this thread, Bitbucket not showing changes in themes directory . But for me, there is no .git or .gitignore files inside either of the .xcodeproj file or xcschemes directory.

How to remove these restrictions so that I can add the new xcscheme file to the repo or is there any other settings that I need to modify?


Solution

  • There are multiple places for gitignore settings. Check them all.

    See the documentation such as http://git-scm.com/docs/gitignore