As someone who likes to keep his notes database clean and organized, I often delete empty or no longer useful notes (Ctrl+Shift+Del). Often, when I do this too fast, I accidentally delete the wrong note, and immediately hit Ctrl+Z in attempt to recover the file from my Recycle Bin, to no avail.
Proposed solution
Since Ctrl+Z is used for Edit Mode undos, I suggest Ctrl+Shift+Z to undo all file movement / deletion related actions (similar to Mac/Windows file navigation behavior). For example, this feature would quickly remediate the following: dragging and dropping files into wrong folder, deleting the wrong note / folder, perhaps even creating a new note by accident?
Current workaround (optional)
I currently have to go to my recyble bin, look for and recover the said file.
You may want to look into using software revision control like âgitâ. I believe there is a plug-in called obsidian-git that helps automate this process.
I have tried several community plugins (for other purposes) and from my experience those can sometimes be a little buggy.
Just curious if there is sufficient community support to warrant this feature as âdefault-behavior-worthyâ to be included in future releases. Or at least added as a Core Plugin. Thanks for the response.
Set up: I have Obsidianâs âDeleted filesâ configured to âMove to system trashâ, and env is Mac OSX Catalina with Obsidian 0.9.15.
Use-case: If 1) I accidentally delete a file from within Obsidian (either by right-clicking -> Delete or by keyboard shortcut, and then 2) I press cmd+z or select âEdit -> Undoâ, nothing happens.
If I go to the systemâs trash and I right click on the deleted note, the usual âPut backâ menu option isnât there and I canât double-click to open the file and copy-paste the contents because you canât open files while theyâre in OSXâs system trash.
Proposed solution
Make Undo and cmd+z actually undo delete file operations if the file still exists.
Make files sent to the systemâs trash have a âPut backâ menu option so that itâs easier to recover them if for some reason you canât recover them from within Obsidian.
Current workaround (optional)
I have to open the systemâs trash and manually move the file to my vault.
@juan Iâm glad we are on the same page on this. I now have the deleted files moved to Obsidian trash (.trash folder) option enabled in my settings, just as a safeguard in case I delete something valuable to my (frequently emptied) recycle bin.
Use case or problem
A new problem now arises, as for some reason, â.trashâ folder does not show up in the file explorer panel on the left, nor does it show up in Ctrl+O searches.
Proposed solution
Display â.trashâ folder in file navigation panel. And make Cmd+Z / Ctrl+Z undo file deletion, similar to my initial post.
I may be a little obtuse (no comments necessary), but why is there an option for sending deleted files to a â.Trashâ if there is no way to access the folder by the User? Or maybe the question should beâŚWhy can I not Recover a deleted file when selecting the UI option âMove to Obsidian trashâ?
I am with you on this as well. The UI is not great.
But the current stop-gap solution at least keeps my accidentally deleted notes âsafeâ, where I can retrieve it manually via file browser if I ever needed to.
I find a third-party solution for that:
you can use google drive to sync your Vault Folder , then when you Try to delete any files in your vault itâs automatically go to google drive trash and you can restore theme easily .
Thanks Issam. I prefer to not add an external dependency like that because it introduces a host of sync issues. For now Iâm relying on both Obsidian Sync and a .git repo within the vault. Itâs not a great experience and Iâm still hit by this issue (yesterday for example), but I can manage until we have undo delete file.
This seems like a pretty obvious and basic feature and I wonder why it isnât there yet?
A simple app like Notes (Mac) allows us to recover a deleted note.
Itâs the kind of workflow that any user would expect from the Undo.
Also, I just noticed that if we use Undo after renaming a note, that wonât undo the renaming of the note (which it should), but it just undoes whatever editing we did on the note itself, which is weird as well.
Please add / fix these things. It shouldnât be expected that user re-learns something that is common in other apps, as well as having to find workarounds for something that should be native.
This link has the technical answer for why âmoving a file to ~/.Trash doesnât give macOS the right metadata to âPut Backâ the file from Finderâ
It looks like Obsidian, (or possibly a plugin) would need to also edit ~/.Trash/.DS_Store â but Iâm unsure if this is supported for third-party appsâŚ