Reveal Time Machine Backup of Selection

I often need to return to previous revisions of files via Time Machine, and I find the process a bit tiresome, so I thought I'd try to automate it a bit.

Setup:

Replace the text in the green action with the path to your main TM directory.

Usage:

  • Select a file you'd like to recover and trigger the macro. You'll be presented with a legible list of available backups.
  • Any backups that contain the selected file at the same location will be indicated with a ✓.

  • Choose a backup and the file will be revealed.
  • If you choose a backup that does not contain the file at that location, the first parent path that does exist in that backup will be revealed. This may be helpful in case the file did exist but has since been renamed or existed elsewhere in your file system at that time. In the latter case, you can use this revealed backup as a starting point to search for it.

Reveal Time Machine Backup of Selection.kmmacros (60 KB)

Macro screenshot

I haven't automated actually recovering the file, but I could do if there's any interest. It's not extensively tested, but no files are being altered (just revealed), so I can't foresee any major issues with it.

5 Likes

Update:

The list prompt now shows which backups contain the selected file at its current location by marking them with a ✓.

Added support for files stored on external media.

2 Likes

Update:

Added support for finding previous backups of files on your TM drive, even if they no longer exist on your current system. In other words, you can navigate around your TM backup and trigger this macro to jump back into its history.

Usage example:

I know that I changed the name of a project folder, so it won't show up in the backup search. That's ok. I can find the place this folder stops being available:

This must therefore be the last backup completed before I changed the folder name. Now I can reveal the folder's parent directory, select the originally named folder and trigger the macro again to see all its backups.

2 Likes

Update:

When the user selects a backup that does not contain the target file at the same location, the first parent path that does exist will be revealed.

1 Like

Hey Neil👋,

Many thanks for posting this…

Another great Macro from you.

Greetings from Germany :de:

Tobias

1 Like

Very nice macro @noisneil. I just downloaded it, and while I haven’t had a chance to test it yet, I know your reputation for quality macros so I have no doubt it’s a keeper. Thanks for sharing!

1 Like

Annoyingly this doesn't work for me since I upgraded to Sequoia. I've tried to find a workaround, but no luck. Hmmph.