a full-featured Backup, Archive, and Restore Tool



BART is a shortcut that can back up, archive, and restore shortcuts in the Shortcuts app Library, also known as My Shortcuts. It is designed to be full-featured, yet simple and fast to use. In fact, most of the information below can be easily discovered by simply running the shortcut. However if you prefer to read instructions and/or learn some of the finer points of BART, the following is for you.

A video overview of BART is available here.

So what's the point?

Short answer: It's always good to back up your work!

Long answer: Stuff happens! On occasion, the iOS Shortcuts app will display an error indicating that the database is corrupt. If iCloud Sync (one of the Shortcuts app settings) is set, the Shortcuts app attempts to recreate My Shortcuts after the error dialog is dismissed. Depending on the circumstances, this restoration can range from a complete recovery to a complete loss of all of the shortcuts in My Shortcuts. If not a complete recovery, shortcut backups are indispensable. Backups are also valuable during more common and frequent events, e.g., if a shortcut is mistakenly modified or deleted.

In addition to shortcut protection, backups can be employed to manage shortcuts. For example, a user might find a group of shortcuts that are useful occasionally, but not want to clutter My Shortcuts with these rarely used shortcuts. Such shortcuts could be archived and restored when needed.

BART Main Menu

This section includes a short description for each Shortcut Operation on the BART main menu.

Save Snapshot of My Shortcuts saves a copy of all shortcuts in My Shortcuts to the snapshot folder: /iCloud Drive/Shortcuts/BART/Snapshot/. All files previously in this folder are deleted before the shortcuts are copied to this folder. This is the fastest and simplest way to back up My Shortcuts.

Back Up Selected saves copy of one or more selected shortcuts in My Shortcuts to the backup folder: /iCloud Drive/Shortcuts/BART/Backup/. Shortcuts files in the folder are written over if the selection includes shortcuts with the same names.

Shortcuts previously backed up to the backup folder and later deleted from My Shortcuts are not automatically deleted from the backup folder. Thus over time, the backup folder will likely contain a superset of shortcuts from My Shortcuts.

Archive All creates a zip archive of the shortcuts in My Shortcuts and saves the file to the archive folder: /iCloud Drive/Shortcuts/BART/Archive/. The archive is named based on the date/time and #x (where x is the number of shortcuts in the new zip archive). For example, the following archive would include 102 shortcuts:

Archive Selected creates a zip archive of one or more selected shortcuts in My Shortcuts and saves the file to the archive folder: /iCloud Drive/Shortcuts/BART/Archive/. The archive is named based on the date/time and either: a) #x (where x is a number 2 to n indicating the number of contained shortcuts), or b) shortcutname (if only one shortcut is selected). For example, the following archive would include 102 shortcuts: and the following would include one shortcut named xyz:

Restore (from a selected folder) displays a list of specified folders that contain shortcut files. Once the user selects one of the folders, a second selection list is displayed with all of the shortcuts within the folder. If the user selects one or more of these shortcuts, they are restored to My Shortcuts.

By default, the folder list contains two folders in /iCloud Drive/Shortcuts/:

  • BART/Snapshot/
  • BART/Backup/

Any other folder in /iCloud Drive/Shortcuts/ can be added to the list by adding it to a List action within BART. This could be useful for users that have used another means to backup and/or organize shortcut backup files. Note: All folder entries are case-sensitive!

Restore (from a zip archive) displays a list of zip archives in the archive folder: /iCloud Drive/Shortcuts/BART/Archive/. If a user selects one of the zip archives, the file is unzipped into a new subfolder in the unarchive folder: /iCloud Drive/Shortcuts/BART/Unarchive/. For example, if the user selected the archive would be unzipped into the following: /iCloud Drive/Shortcuts/BART/Unarchive/2019-12-10-073522_#102/. After the archive is unzipped, a second selection list is displayed with all of the shortcuts within the subfolder. If the user selects one or more shortcuts, they are restored to My Shortcuts.

Restore (from an unarchive folder) displays a list of subfolders in the unarchive folder. If a user selects one of the subfolders, a second selection list is displayed with all of the shortcuts within the subfolder. If the user selects one or more shortcuts, they are restored to My Shortcuts.

This restoration operation would be used to recover a shortcut that was previously archived (using Archive All or Archive Selected) and then subsequently unzipped using the Restore (from a zip archive) operation.

Restore One (from a file browse) will open a file selection dialog to allow the user to select a shortcut file. The selected shortcut will be restored to My Shortcuts.

This restoration operation would likely be used infrequently as it is intended for files that were backed up prior to using BART. This method has the advantage of being more flexible in that the shortcut file can be located anywhere, not limited to /iCloud Drive/Shortcuts/. The disadvantage of this method is that only one shortcut can be selected per file browse.

Help displays this information.

Segregating Saved Files by iOS Device

By default, all files created by BART are saved exactly as described in the above sections. This is appropriate if:

  • only one iOS device is being used, or
  • if multiple devices are being used and iCloud Sync is ON for all devices (that use BART).

Conversely in cases where multiple iOS devices are being used and iCloud Sync is not being used, it is recommended to segregate the BART files. This change can be made when BART is first downloaded or at anytime later using Settings -> Customize Shortcut.

If segregation is selected, the BART root folder becomes: /iCloud Drive/Shortcuts/BART/device_name. For example, if the device name is My iPhone, the folders mentioned in the previous section would be subfolders of /iCloud Drive/Shortcuts/:

  • BART/My iPhone/Snapshot/
  • BART/My iPhone/Backup/
  • BART/My iPhone/Archive/
  • BART/My iPhone/Unarchive/

Shortcut and Workflow Files

Shortcut files saved to iCloud Drive by BART include a shortcut extension (e.g., xyz.shortcut).

The Shortcuts app is an updated version of Workflow, a third-party iOS app that Apple acquired in 2017. Although similar, this app included workflows, not shortcuts. Workflow files included a wflow extension and, like shortcut files, can be restored using BART.

Restoring Shortcuts

With iOS 13.x, the Shortcuts app cannot restore/import a shortcut file directly from iCloud Drive. (This limitation did not exist with the iOS Workflow app, but may have been added by Apple for security reasons.) Therefore to restore/import a shortcut, the shortcut file must first be uploaded to iCloud (in a public area established by Apple that is reserved for shortcuts). Once uploaded, a shortcut file can then be restored/imported within Safari by opening an iCloud link (to the uploaded shortcut file).

BART automates the process described above. However once the link is opened in Safari, a user must complete the final step by selecting blue Get Shortcut button that appears on the shorcut's Safari page. Because of a limitation with the Shortcuts app, this final step cannot be completed if a shortcut is still running. Due to these constraints, only one shortcut can be automatically restored/imported for each run of BART (or any similar restoration shortcut). Therefore if the user selects more than one shortcut to restore, the first one will be restored during that run of BART; shortcuts 2 to n will be queued up and ready to be restored, one at a time, with each subsequent run of BART.

Optional Management of iCloud Folders

As mentioned above, snapshot, backup, and archive files are saved to /iCloud Drive/Shortcuts/ subfolders, specifically BART/Snapshot/, BART/Backup/, and BART/Archive/, respectively. In general, the contents of these folders are managed automatically by BART, but in some cases the contents can be managed manually using the iOS Files app or the macOS Finder. Specifically:

  • Shortcuts no longer needed but previously backed up to BART/Backup/ can be manually deleted.

  • Shortcuts files (*.shortcut), and even old Workflow files (*.wflow), can be manually added to BART/Backup/. These shortcuts (or workflows) can be restored using the Restore (from a selected folder) operation.

  • As an alternative to the above bullet, old Shortcuts app (or Workflow app) backups could be managed in a separate folder(s) within /iCloud Drive/Shortcuts/. Files in this folder(s) can be restored using :

    1. Restore One (from a file browse).
    2. Restore (from a selected folder). In this case, the /iCloud Drive/Shortcuts/ subfolder(s) would need to be added to the folder list using the List action within the shortcut. This list appears near the top of BART and includes a preceding comment. Note: All folder entries are case-sensitive!
  • Unneeded zip archive files in BART/Archive/ can be deleted.

  • Older zip archives that include shortcuts (or even workflows), that may have been created by some other means, can be manually added to BART/Archive/. BART could then be used to process these archives just as it does for the archives that it creates.

  • Unarchive subfolders in BART/Unarchive/ can be deleted (e.g., BART/Unarchive/2019-12-12-131131_#109). Also, shortcuts no longer needed can be individually deleted from these subfolders.

  • Note: Shortcuts files can be copied from BART/Snapshot/, but since this folder is automatically managed by BART, the folder contents should not be modified.

Running BART From Another Shortcut

BART can be optionally started from another shortcut. This is also known as running BART in Input mode. This mode is useful because routine tasks can be automated and run consistently and quickly without user interaction with the BART main menu.

Note: The following information in this section will be easier to understand if the four shortcuts included at the end of the section are first downloaded and inspected.

To run BART in this mode, the calling shortcut needs two actions: Dictionary and Run Shortcut.

This Dictionary information is used by BART to determine the desired Operation (in lieu of user interaction with the BART main menu). Depending on the BART Operation, the Dictionary action must have one or two Dictionary Items: [item 1: Key = Operation] or [item 1: Key = Operation; item 2: Key = Shortcut].

The following one-item BART Operations are supported:

  • Dictionary[item 1: Key = Operation, Text = Snapshot]
  • Dictionary[item 1: Key = Operation, Text = Archive All]

And the following two-item BART Operations are also supported:

  • Dictionary[item 1: Key = Operation, Text = Back Up; item 2: Key = Shortcut, Text = shortcut_name]
  • Dictionary[item 1: Key = Operation, Text = Archive; item 2: Key = Shortcut, Text = shortcut_name]]

As mentioned above, the above Dictionary action must precede the Run Shortcut action (specifically Run[BART]).

Note 1: In the second group of BART Operations, a third key [Key = Shortcuts] can replace the second key [Key = Shortcut]. This must be employed when backing up or archiving more than one shortcut with a single Dictionary/Run[BART] pair. In this case, the Dictionary item must be an Array, with Key = Shortcuts, and the shortcut_names are entered as separate Text array items.

Note 2: The functionality in this section is much more complicated to describe than to actually use. The following example shortcuts demonstrate each of the four operations discussed above:

  1. Call BART (Snapshot)
  2. Call BART (Archive All)
  3. Call BART (Back Up)
  4. Call BART (Archive)

Shortcut Automation

The shortcuts mentioned in the previous section, Running BART From Another Shortcut, are great candidates for the Shortcuts app Automation, also known as personal automation in the Shortcuts User Guide. As an example in the two following videos, Call BART (Archive) is used to demonstrate how a full archive can be executed at 11:30/pm everyday.

Shortcut Testing

BART has been tested with the following:

  • iOS 13.3.1 (17D50)
  • iPhone 8 Plus
  • iPad Pro 10.5"
  • Shortcuts app Libraries exceeding 1000 shortcuts

Shortcut Development and Acknowledgments

  • BART is available exclusively at Versions obtained elsewhere might be out-of-date.

  • The framed screenshots were created using the shortcut Apple Frames (iOS) from the MacStories Shortcuts Archive.

  • The menus in this shortcut use Apple SF Symbols that were encoded using another shortcut SF Symbol for vCard Menu. That shortcut uses the Create Icon action included in the premium version of Toolbox Pro.

  • BART checks for updates of itself every 7 days (and if the user selects Check for Update on the main menu) using Embed-a-Update (Version: 1.1.2, Updated: 10/13/19).

Latest Release Notes

1.6 - Feb. 8, 2020, 4:26 p.m.

- Added a configuration parameter: Segregate Backup Files by iOS Device
- Updated the Help describing this new parameter

Past versions