Help! All my tabs and backups files disappeared
So I tend to keep some daily notes in Notepad++ and then once every quarter or so I archive them off into a large text file sorted by date. I had like 15 tabs open today. And I was doing something like a copy/paste, or Alt-Tab, I don’t remember exactly what but some control key combination. I definitely fat-fingered something, not sure what key combination I hit. Anyway all of my tabs disappeared and I was left with only a blank “new2” tab. That seemed odd, so I restarted Notepad++ expecting it to load the old tabs from backup but it didn’t. Annoying but ok I’ll just drag them in manually. Except when I went to look in C:\Users<user>\AppData\Roaming\Notepad++\backup it was completely empty. There was nothing there at all. This is where Notepad++ keeps all of my document backups and is the main reason why I use it. Does anyone know what happened and why my backups failed?
Does anyone know what happened and why my backups failed?
Without a time machine and knowing where you are to look over your Past Self’s shoulder, the best I can do is guess. Ctrl+Shift+W (File > Close All) would have closed all open files. But if you had unsaved work in there, it should have prompted you before closing them all. (Unless the Ctrl+Shift+W was unfortunately immediately followed by a keystroke that was interpreted as “yes to all” by the dialog that popped up momentarily). But if it did think it got a “yes to all”, then the periodic-backups files were deleted, because as soon as Notepad++ closes an unsaved file with user confirmation, it will delete those files.
The session-snapshot-and-periodic-backup feature is trying to prevent such things, but no one backup feature is foolproof (especially as we fools get more “skilled” / unlucky). The session-snapshot-and-periodic-backup files are not intended as long-term data backup, but rather as short-term protection against some events outside your control. The more unsaved files you have open, the more you are opening yourself up to data loss.
Reading our backup FAQ will help you take a more proactive role in your data integrity. If you follow the best practices described in that FAQ, you can lessen the chances of significant data loss in the future.
@PeterJones This seems like a pretty good explanation. At least the first part. I will agree I might have hit Ctrl-Shift-W to start things off.
So I tried that out in a mock scenario with a few open tabs to see what the UI flow looks like. And with a few tabs open, pressing Ctrl-Shift-W shows a confirmation popup to save every tab into its own file. The options were Yes, No, Cancel, Yes to all, No to all. I didn’t see any confirmation popup at the time of the incident, though if I was already pressing a hotkey for one of the buttons it might have immediately processed that and dismissed the popup window.
Importantly, the only way in which all tabs are deleted instantly without further popups is if the user selects “No to all”. But the hotkey for that is the letter “o”. That letter is VERY far away from the key for the letter “w” which we’ve decided I must have been pressing to initiate a close all tabs command. So this part doesn’t vibe. My finger slipped yes, but I didn’t faceroll the keyboard. It’s hard to believe I was pressing Ctrl-Shift-W-O with one hand all at the same time.
It’s still a bit of a mystery, but in the meantime I’ve cleared the hotkey for Close All. I can go up and select it from the menu when I use that feature maybe twice a year :)