Where is my idea/workspace.xml file located? I cant find it in Pycharm, I cant find it in finder (searched entire Mac). I get the error error: Your local changes to the following files would be overwritten by checkout: .idea/workspace.xml which I know has been asked alot. I tried ignoring the file with no luck (maybe because I accidentally committed it previously), and I tried adding it a bunch of different ways with no luck. Is the right thing to do to remove it from the repo (not sure how to do that) or to continue to add it, if the latter where do I find this thing.. How did it accidentally get committed if I cant even find it now.
- Are you on a unix OS?JacobIRR– JacobIRR2017-11-20 00:25:39 +00:00Commented Nov 20, 2017 at 0:25
1 Answer
It is located in the root folder of the respective project, in the hidden folder .idea, along with other PyCharm project settings.
From the official documentation:
All the settings files in the .idea directory should be put under version control except the workspace.xml, which stores your local preferences. The workspace.xml file should be marked as ignored by VCS.
According to this, the right course of action would be to remove the file from the repo, and add the following line to the .gitignore file:
.idea/workspace.xml Keep in mind that this is what JetBrains as the developers of PyCharm recommend, your project manager or colleagues might have another opinion on the matter.
3 Comments
git rm --cached .idea/workspace.xml but it is saying it did not match any file. I can see the file in my repo however...git ls-tree --full-tree -r HEAD i see the file idea/workspace.xml. However everytime i try to remove it i get the same fatal: pathspec 'idea/workspace.xml' did not match any files