Is there a way to prevent PyCharm / IntelliJ from removing empty folders?
I write output files to a folder in my project. When I delete them, the default behaviour of PyCharm is to remove the empty folder.
Can I prevent this?
Select an item you want to delete. Select Refactor | Safe Delete from the main or context menu or press Alt+Delete .
In the Settings/Preferences dialog Ctrl+Alt+S , click Directories . In the Exclude files field, type the masks that define the names of files and folders to be excluded, for example, *.
When you delete the last file in a directory from Git in the command line (git rm dir/file.txt
), Git itself automatically deletes the whole directory.
In other words: IDE behaves the same as Git does.
Can I prevent this?
Nope. At least not at the moment.
http://youtrack.jetbrains.com/issue/IDEA-75590 -- watch this ticket (star/vote/comment) to get notified for any progress.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With