-
Notifications
You must be signed in to change notification settings - Fork 29.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Option to disable Undo/Redo for File Operations #117621
Comments
This is a fair feature request, however we do not have it on our immediate plan. Thus assigning to backlog and we might add this in the future. Thanks |
Thanks @isidorn! |
When navigating between files, and often selecting a file that you just recently did some change to (in the code), and at the same time having some changes made to the files themselves (e.g. copying, renaming, moving files via the file navigator), I often click Undo/Redo EXPECTING my code to update, but sometimes it will have catastrophic consequences, such as deleting an entire codebase with no ability to "Redo/Undo" to retrieve any of the lost code. Didn't commit? well, have fun trying to reconstruct your last three hours of your coding session - because it's gone and you have no way to get it back! Please - allow some way to disable this demonic "feature". When I click on a file in the file navigator, I expect the code editor to be the active element that any and all actions will be performed on. Having the focus stay on the file manager is utterly unintuitive and requires high attention to details to not mess up a work in progress. |
This is highly frustrating. |
From the Stackoverflow thread mentioned by the OP, here's a quick fix that you can use by modifying the keybindings json to the following:
|
I would like to disable all keyboard operations for the file explorer, period. I just had to reconstruct missing files/folders that were appearing/disappearing, I have no idea how these things even were happening. I'd prefer no files get deleted, undeleted/redeleted etc unless I use the mouse and menu actions to perform file operations. |
I would like to reiterate that this needs to be addressed. I'm not sure why this feature was implemented, but it's caused me much grief. The behavior is unexpected and I find that I end up accidentally undoing file explorer operations when I had no intention of doing so several times per day. I've not once ever wanted to undo anything done in the explorer. So, this feature has introduced daily frustration to solve something that was never a problem. Behavior like this should be toggle-able and defaulted to disabled. |
Why is this still an issue??? The issue wouldn't be so bad if the REDO command actually worked. The feature is broken and should never have made it to production. It's been an issue for 6 month, I spent a month on sublime due to this issue. been pretty good and just had a folder complete get erased, not in the garbage can, not anywhere. just f'in gone, and redo gave me an empty folder.. |
This is an absolute joke!! The guy who thought of this "feature" needs to be put into prison for life!!! What are you thinking vscode team??? You have shown a lack of user commitment. GET RID OF THIS NOW!!!! |
I think is a cool feature, however it needs to be confirmed by the user before doing it. |
I would like to point out that I too fell victim to this diabolic "feature". |
This is the most dangerous feature ever developed. PLEASE REMOVE IT! |
Hello all, I recently acquired this ticket. It seems there may be separate issues going on here and I want to make sure I understand the problem fully. The issue title requests a way to disable undo/redo for file operations, but in the comments I see folks saying that they've experienced dataloss due to these operations. To me these seem like different issues: undo/redo causing dataloss sounds like a bug, and disabling the operations sounds like a request. It would be helpful to me if someone could give a step by step description of how the dataloss is occurring (a screen recording on gifcap.dev would be helpful), and I will look to see how to fix that dataloss (the solution may indeed be to provide an option to disable file operations, but I don't know until I see what exactly is going on here). I have tested with undoing/redoing renaming folders, nested folders, and files and did not experience dataloss. I am aware of an outstanding ticket regarding undoing a folder deletion not working ( #111022) however I'm not sure this is what's happening here, as in that case the files are still available in the trash and the user explicitly requested they be deleted. |
@JacksonKearl Data loss is caused because undo/redo operations in File Explorer are executed without prompting the user. The thread above gives many examples where users have experienced this, and the enormous damage it can cause. I think this can be summarised as the following requests:
|
@space-alien I will address any dataloss issues with the highest priority, but I can not if I do not have reproducible steps. No reproducible steps have been written in this thread to-date, and in my testing I did not come across any dataloss myself. While I believe that dataloss may be occurring, I cannot fix it if I cannot see it (or at least see a general flow that may cause it) If you want this resolved quickly, please, provide reproducible steps. |
To reproduce, click on a folder in the vscode file sidebar |
@gravity-addiction thanks, based on that a concrete step forward would be to show the delete folder prompt on undoing a paste folder operation. It's worth noting that in this case the "deleted" folder does still exist in the trash and the data is recoverable. |
@JacksonKearl Thank you for the quick response on this. Perhaps any kind of deletion operation should give rise to the confirmation prompt - not just folder deletion. Work could also be lost by deleting copied files without warning, if that's where a developer starts making changes without renaming the new file. |
I just discovered this: https://github.com/microsoft/vscode-docs/blob/vnext/release-notes/v1_53.md#:~:text=We%20also%20show%20a%20confirmation%20dialog%20for%20destructive%20undo%20operations%20from%20the%20Explorer. Perhaps this feature was not released after all, or since regressed? I would also like to reiterate the request for a setting to disable undo/redo file ops in the Explorer. I just found myself inadvertently restoring deleted files - another non-delete operation I would like prevented by a setting or a confirmation prompt. |
@space-alien do the keybindings referenced here work for you? |
I literally just crashed my project because the undo removed all of my node modules. Although reinstalling node modules is an easy task I have lost multiple files and hours of work since the release of this feature. |
To me, this is just about permanently deleted! Yes, they end up in the trash, but on a macOS, my trash is enormous and you lose all the path info and spend hours at times trying to know what the hell it just deleted and where you need to restore it to. So let say you have not to edit some files (made a new one, move a folder, rename a file) in many days, and your editing your code and then say OK that idea did not work and I would do a undo about 2 to 5 times thinking I am removing my last 2 to 5 edits in that file but did not know my pointer still inside the explorer and BAM! I just mess up my file system with the last 2 to 5 things I did in there over the last few weeks. I do commit my changes but not every day or every hour so that is no help. This has happened over 3 to 5 times so far and HATE this as this is not a feature as this is a job killer as it cost time and money. |
This diabolic feature still exists? I just undid hours of work. When are you going to address this? Its been months since we started complaining. |
Same @tawani :( it was a very bad experience! Luckily I found my lost files in the trash and with some more work I was able to glue all the pieces back together. |
I didn't encounter this issue until i had to work with creating/updating several folders and files at once. For now I'm just reminding myself to close the window and reopen after every few changes to make sure there's nothing to delete when I accidentally undo. |
@JacksonKearl OP here. As @gravity-addiction pointed out |
This feature is hell *tired, can we just remove it please guys |
I'll chime in again, but I actually see the utility of this feature. It's nice to be able to copy and paste directories, as well as undo. But I think there should be an option to warn on file system undo as well as completely disabling it. It can be a highly destructive action and warrants confirmation from the user. Maybe it could be an option with |
REMOVE THIS #$^&%@#!$ FEATURE OR GUARD IT WITH A CONFIRMATION DIALOG!!! |
This is a terrible experience. I just lost about a day of work to this behavior. I don't know if it's related to working on a filesystem where vscode can't put things in trash, or if the undo buffer is too small or who knows, or if i accidentally did a real operation somewhere making vscode throw away the redo stack. Regardless of how it happened, I don't think it's a good idea to hijack such a common hotkey for destructive behaviors like deleting files and folders. |
Wow had my first run in with this, what a silly feature.. |
If this feature exists it should exist disabled by default. |
Lost entire directory... It's not the first time I think I am undoing inside the text editor but I'm undoing in the directories. I can not hate this thing more ^^' |
In today's insiders is a new setting Please do let me know if you encounter any deletion events that are not properly warned about under the new |
Holy shit, who in their right mind thought this was a good feature? |
I gotta say, this and the undo after close/open are the kind of 'features' that make me HATE a program that I used to love. Making seemingly arbitrary changes to a default workflow that has existed for YEARS is a recipe for disaster, and this one is particularly nasty. I mean, what developer in their right mind would want such a destructive change to the default workflow of a program they have been using for any extended period of time? I had inadvertently been on an older version of VSCode for a while, and only discovered this madness recently. It has completely blown my workflow and caused me a LOT of problems. |
With tomorrow's Insiders (next week's Stable) this is now split this into two settings, |
Thanks so much @JacksonKearl. Really appreciate the response on this |
Multiple times since the "Undo File Operations" feature has been released, I've experienced accidentally undoing file renames/deletions. This has caused me a lot more trouble than it's worth. I've lost time undoing unknowingly altering my file system and even automatic name changes in other files related to auto renaming. A prompt isn't enough for me. I simply find the feature harmful to my workflows and would like to have the ability to turn it off. I know others have also found it difficult as well
The text was updated successfully, but these errors were encountered: