Initially, I had everything that was contained in my main branch.
Then I decided to split Windows and Windows branches on the Mac, and the master branch only tracks source code files. Therefore, I only began to stage changes in source code files when in the main branch, and merge these source code changes with Mac and Windows branches as needed.
The problem is that when I initially tracked everything in my main branch, I also tracked the project file. Thus, I would add new files to the project and compile it on Mac and Windows, but when switching back to the main branch, the project file also switches to the old version, which leads to compilation failure.
So, how can I stop tracking the project file in the main branch? I do not want to stop tracking it in my Mac or Windows branches, and I do not want to remove it from earlier versions in the main branch.
git version-control
wrongusername
source share