-1

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.

1
  • Are you on a unix OS? Commented Nov 20, 2017 at 0:25

1 Answer 1

4

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.

Sign up to request clarification or add additional context in comments.

3 Comments

hello, I am trying to remove it from the repo with 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...
@ratrace123 Are you talking about the local or the remote repo? You might to look at this question.
i am talking about the local repo, when i run the command 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

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.