Naive Git setup, is it possible to track files listed on my .gitignore?

I made a naive mistake when setting up my project. We are working on one remote repository. When setting up git, we never thought that Xcode would create files without development and push them to our remote repo. Now, as soon as I found out after the failure and recording, I made a file .gitignore.

.gitignore looks like this, please let me know if I edit this too. (Ignoring the file too: Answer to this question from Abizem)

# Mac OS X
*.DS_Store

# Xcode
*.pbxuser
*.mode1v3
*.mode2v3
*.perspectivev3
*.xcuserstate
project.xcworkspace/
xcuserdata/

But now the question is, is there any way that I can track all of the listed files from our source control?

or

,

git rm --cached 'file path'
+5
1

-, , - ( .gitignore), :

git add --all
git commit -m "Remove all files"

:

git add --all
git commit -m "Re-add files"

gitignore.

+6

All Articles