Ignore files from specific context root
I like to have my own scripts and utilities for a given git based project, so I have this:
- Clone project at ~/project
- Set up a personal git repository and clone in it ~/extras
- Open ~/project in PhpStorm
- Add ~/extras as Content Root, so I can add and edit my utilities from the main project
- Every now and then, open ~/extras alone in PhpStorm and commit+push changes to remote repository
I did it a long time ago so I've surely missed some other detail.
Starting today, all the non-committed files at ~/extras have started appearing in the “Commit” pane in main project. I'm not aware of having changed anything and, if I did, I didn't realise I did. It was working fine after I upgraded to 2023.3.1, it only started happening when I launched the IDE today. I've been through all the “Repair IDE” steps to no avail.
What can have caused that behaviour change?
Please sign in to leave a comment.
Alright, I found it. I restored my projects from a backup copy and I used Meld to compare everything in bulk. There was some XML file inside “.idea” where I got a new “VcsDirectoryMappings” entry for the extras. It seemingly happened when I edited protected branches at “Version Control/ Git”.
Is there a GUI tool to handle these mappings? I don't even see it in the dialogue that caused it all.
Edit 1: I don't understand anything… The changes disappeared when I closed the IDE and removed the entry from the XML file. But files get back after a few minutes :-!
Edit 2: fixed with https://www.jetbrains.com/help/phpstorm/settings-version-control-directory-mappings.html . I need to add the mapping shown under “Unregistered roots” and then select “VCS: <none>”
No idea why this started this morning.