You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Please remove "Undo feature" (Ctrl+z) in file explorer side. I have created lots of files and when I tab from text editor to the file explorer tab side, by accidentally press Ctrl+z it undoes all my created files. so I lost a lot of codes. Sad with Ctrl+z feature in file explorer VSCode.
VS Code version: Code 1.52.1 (ea3859d, 2020-12-16T16:34:46.910Z)
OS version: Windows_NT x64 10.0.18363
Thanks for feedback. We will not remove it, but we might introduce a prompt.
Let's leave this open for now so other users can also chime in with their opinion.
This (combined with #111640) is the most dangerous behavior of VS Code that I have encountered (actually, of any IDE, ever). I lost hours of uncommitted work by pressing Cmd-Z just 4 times when I thought the editor had context. It's baffling that the explorer pane has its own memento stack so it will delete files created days earlier after numerous changes in the editor pane. Worse, I can't even reproduce it with a fresh run, which tells me that VS code is getting its undo stack confused after hundreds of edits.
My suggestion is that the explorer pane not have any undo functionality (or at least make it an opt-in setting). It doesn't make sense to even try when the majority of files appear and disappear though external means (e.g. ng generate or git branch operations).
Thanks to work with Alexandru Dima (@alexdima) we have now changed that we prompt when undoing a creation operation
We can change this to prompt in more cases if needed.
Try it out and let us know how it goes. We can also add an option "Do not show again", but let's not do this yet (since we can only nicely reset this if we introduce a setting).
Activity
isidorn commentedon Dec 17, 2020
Thanks for feedback. We will not remove it, but we might introduce a prompt.
Let's leave this open for now so other users can also chime in with their opinion.
[-]Undo mistake[/-][+]Prompt before destructive Explorer undo[/+]johnchurchill commentedon Dec 26, 2020
This (combined with #111640) is the most dangerous behavior of VS Code that I have encountered (actually, of any IDE, ever). I lost hours of uncommitted work by pressing Cmd-Z just 4 times when I thought the editor had context. It's baffling that the explorer pane has its own memento stack so it will delete files created days earlier after numerous changes in the editor pane. Worse, I can't even reproduce it with a fresh run, which tells me that VS code is getting its undo stack confused after hundreds of edits.
My suggestion is that the explorer pane not have any undo functionality (or at least make it an opt-in setting). It doesn't make sense to even try when the majority of files appear and disappear though external means (e.g. ng generate or git branch operations).
isidorn commentedon Jan 18, 2021
Thanks to work with Alexandru Dima (@alexdima) we have now changed that we prompt when undoing a creation operation
We can change this to prompt in more cases if needed.
Try it out and let us know how it goes. We can also add an option "Do not show again", but let's not do this yet (since we can only nicely reset this if we introduce a setting).
fyi Johannes Rieken (@jrieken) in case you are interested in changes d427dea
I think it was pretty straight forward.
isidorn commentedon Jan 18, 2021
To verify: