code icon indicating copy to clipboard operation
code copied to clipboard

Do not allow projects to be moved to trash from the sidebar

Open arshubham opened this issue 7 years ago • 5 comments
trafficstars

Don't allow moving project folder to trash or at least throw a warning. The reason is if the project folder is removed and trash is emptied later, there is no way to restore the contents. Within a project this can be mitigated by using git but removing the entire project removes .git directory making it impossible.

arshubham avatar Mar 29 '18 18:03 arshubham

Never use a warning when you mean "Undo" ;)

danirabbit avatar Mar 29 '18 18:03 danirabbit

Ok, I meant a message dialog to warn user they are about to move a project to trash

arshubham avatar Mar 29 '18 18:03 arshubham

Over-using warnings is kind of a habit-forming anti-pattern. Check out this article: http://alistapart.com/article/neveruseawarning

danirabbit avatar Mar 29 '18 18:03 danirabbit

I understand but a better option here could be to close the project instead of moving it to the trash. For example vscode or atom don't allow deleting the project.

image image

Code shouldn't act as file manager

arshubham avatar Mar 29 '18 18:03 arshubham

I am inclined to simply remove the "Remove to Rubbish" context menu item for project folders.

jeremypw avatar Jun 17 '25 15:06 jeremypw