Skip to Content

Workflows

A workflow is a ready-made script for an everyday job, such as verifying a backup, finding photos that were never copied, or comparing three versions of a folder. You pick one, fill in the folders it should look at, and run it. You don’t have to write any JavaScript, and you can open any workflow’s source to read it, change it, and learn from it.

Workflows come with DeltaWalker Classic. Each one is described in the file scripts-metadata.json in the samples/scripting/javascript folder of the installation: its title, what it does, its category, how hard it is to follow, how much it can change on your computer, and the settings it asks for. DeltaWalker Classic reads that file to build the Workflow Gallery and the Workflows menu.

Workflows are part of DeltaWalker Classic Standard, Pro, and Oro, and of the trial. Writing and running scripts of your own is part of Pro, Oro, and the trial; see Scripting DeltaWalker Classic. DeltaWalker Classic Free and the Mac App Store edition have no workflows, no Workflows toolbar button, no Script menu, and no Workflow Gallery card on the Welcome page.

Where to find workflows

  • The Workflows button on the main toolbar. Click the button itself to open the Workflow Gallery. Click the arrow next to it to open a menu with:

    • the workflows you ran or opened most recently, up to ten, newest first, followed by a separator;
    • six featured workflows: Protect Photos…, Verify Backups…, Organize Downloads…, Find Missing Files…, Clean Up Desktop…, and Mirror Folder Safely…, followed by a separator;
    • Open Workflow Gallery…, New Script…, and Open Script….

    Choosing a workflow in this menu runs it. If the workflow has settings, the Configure Workflow dialog opens first.

  • File > Script > Workflows is the same menu. File > Script > Workflow Gallery… opens the gallery directly.

  • The Welcome page has a Workflow Gallery card. See Welcome Page.

The Workflow Gallery is a view with one card for each workflow.

  • Search filters the cards as you type. It looks in each workflow’s title, description, and category, and ignores capitalization.
  • The category buttons below the search field narrow the cards to one category. All shows every workflow. The categories are Backup Verification, File Organization, Media Workflows, Development Workflows, Async Patterns, and App Control.
  • Each card shows the workflow’s title, three small labels (its category, its safety level, and its difficulty: Beginner, Intermediate, or Advanced), a description, and a note about what the workflow does to your files. The card is tinted by safety level: green for Read-only, blue for Reporting, and yellow for Can modify.

At the bottom right of each card are these buttons:

ButtonWhat it does
RunRuns the workflow. If it has settings, the Configure Workflow dialog opens first; Cancel there runs nothing. The Script Editor does not open.
ConfigureAppears only on workflows that have settings. It opens the same Configure Workflow dialog and, after OK, runs the workflow.
Open SourceOpens the workflow’s script in the Script Editor without running it. Use it to read the script, change it, or save your own copy.
DebugOpens the script in the Script Editor and runs it there, so that breakpoints and debugger statements can pause it. If the workflow has settings, the Configure Workflow dialog opens first. See Script Editor and Debugger.

If no workflow matches the search and the category you chose, the gallery says No workflows match the current filter.

Safety levels

The safety level tells you what a workflow can do to your files before you run it. The card’s note repeats it in the workflow’s own words.

LevelWhat it means
Read-onlyReads files and folders and shows what it found in the Console. It writes nothing and changes nothing.
ReportingReads files and folders and writes a report, usually an HTML file whose location you choose. It does not change the files it compares.
Can modifyCan copy, merge, or otherwise change files. Read the card’s note and the script before you run it.

The safety level is a description written by the workflow’s author, not a restriction that DeltaWalker Classic enforces. A script that you edit can do more than its card says.

Configure Workflow dialog

The dialog is titled with the name of the workflow. It shows the workflow’s description, then its safety note in a warning color, then one row for each setting. Click OK to run the workflow with the values you entered, or Cancel to run nothing. The dialog can be resized.

Each setting has a label ending in a colon, and the control depends on the kind of setting:

  • Folder and file settings are a text field with a Browse… button. For a folder, Browse… opens a folder chooser. For a file, it opens a file chooser, which can pick only a file that already exists; to name a file that doesn’t exist yet, such as a new report, type its path in the field.
  • A checkbox setting is a check box. It starts unchecked unless the workflow says otherwise.
  • A dropdown setting is a list from which you choose one of the workflow’s options.
  • Text and number settings are plain text fields. A number setting that doesn’t contain a number is replaced with 0.

The fields start with the values from the const lines of the workflow’s script, where it has them; a field can start empty. Leading and trailing spaces are removed from what you type.

How the script receives the values

Inside the script, each value is available as workflow.<id>, where <id> is the name of the setting. For example, workflow.SOURCE is the folder entered for the setting named SOURCE. The values are text; a checked checkbox gives "true" and an unchecked one gives "false".

The workflows that come with DeltaWalker Classic keep their settings in const lines near the top of the script, for example const SOURCE = ...;. For a run, DeltaWalker Classic puts your values into those lines in memory. The file on disk is never changed by the dialog.

When a setting has no effect

A setting changes a run only if the workflow’s script reads it. In this release not every workflow does. For example, in Verify Backups the Source Folder and Report File you enter are used, but the backup location is still the one written in the script. So check the folders a workflow prints at the start of its output in the Console. If they are not the ones you chose, click Open Source, change the paths in the const lines at the top of the script, and run it from the Script Editor.

Where the output goes

A workflow reports what it finds in the Console. When you click Run or Configure, the Console opens by itself, and it is cleared each time a script starts. Workflows that write a report also save it to the file named in their settings. Open the Console again with Window > Show Console.

The workflows that come with DeltaWalker Classic

These are all the workflows in the gallery, in the order the category buttons list them.

Backup Verification

WorkflowWhat it doesSafety
Verify BackupsCompares a source folder with its backup drive and writes an HTML report of what is missing or changed.Reporting
Protect PhotosFinds photos in your Pictures folder that are not yet on the backup drive, and shows what still needs to be copied. Writes an HTML report.Reporting
Verify Multi-Drive BackupChecks that a source folder is protected on both a primary backup and an offsite backup, comparing the two in parallel.Read-only

File Organization

WorkflowWhat it doesSafety
Find Missing FilesShows which files are on one side of a folder comparison but not the other. Useful for any pair of folders that should match.Read-only
Organize DownloadsCompares your Downloads folder with Documents and Pictures in parallel, to show what is already organized and what still needs to be moved.Read-only
Clean Up DesktopFinds Desktop files that already exist in Documents or Downloads, and so are safe to remove from the Desktop.Read-only
Archive ScreenshotsFinds screenshots on your Desktop that have not yet been moved to a Screenshots archive folder.Read-only
Mirror Folder SafelyCompares two folders in both directions, lists each difference, and can optionally synchronize them. As shipped, the synchronizing steps are commented out, so the workflow only inspects until you edit the script.Can modify

Media Workflows

WorkflowWhat it doesSafety
Sync Phone ExportsFinds photos in a phone export folder that are not yet in your main Pictures library, and shows what still needs to be imported.Read-only

Development Workflows

WorkflowWhat it doesSafety
Compare Project VersionsCompares two snapshots of a project folder and prints a summary of new, changed, and removed files. Can also write an HTML report.Reporting

Async Patterns

The seven workflows whose titles begin with Async: are learning samples for scripts that wait for comparisons, run several at once, or handle errors. The category also holds examples of three-way synchronizing and merging, remote folders, filters, and printing. Open a workflow’s source to see how it is written.

WorkflowWhat it doesSafety
Async: Fire and Await LaterStarts a comparison and waits for the result only when the script needs it.Read-only
Async: Sequential WorkflowCompares two files, then writes an HTML report, each step waiting for the one before.Reporting
Async: Batch SequentialCompares several pairs of folders one after another in a loop.Read-only
Async: Parallel CompareRuns several comparisons at the same time with Promise.all, so the total time is that of the slowest one.Read-only
Async: Error HandlingUses try/catch to handle comparison errors and other failures.Read-only
Async: Mixed OrchestrationRuns comparisons in parallel, then writes the reports one after another.Reporting
Async: Compare and Report HelperWraps a comparison and its report in a function that any script can reuse.Reporting
Three-Way Folder SyncCompares three versions of a folder at once and synchronizes the changes that don’t conflict. These operations modify files.Can modify
Remote Folder CompareCompares a local folder with a folder on an FTP or SFTP server.Read-only
Folder Compare with FiltersApplies path filters to a folder comparison, to focus on certain file types or subfolders.Read-only
Three-Way Text MergeCompares three versions of a text file, merges every block that doesn’t conflict, and saves the result to a new file. The original files are not modified.Can modify
Text Compare, Print and ReportCompares two text files, then prints the comparison to PDF (macOS) and writes an HTML report.Reporting

The Async: samples, Text Compare, Print and Report, and Mirror Folder Safely compare the sample files and folders that come in the samples folder of the installation: f0, f1, f2, q0.txt, q1.txt, and q2.txt. The scripts expect them in a test/samples folder inside your home folder. Copy them there, or click Open Source and point the script at your own files, before you run these workflows.

Five text-comparison examples print the number of deltas with a call that text comparisons don’t have: Async: Fire and Await Later, Async: Sequential Workflow, Async: Error Handling, Async: Compare and Report Helper, and the third comparison in Async: Parallel Compare. In these, the comparison finishes and then the Console shows an error instead of the count. In Async: Sequential Workflow that happens before the report is written; in Async: Error Handling the script’s own catch prints it. To count the deltas of a text comparison in your own scripts, use getAllDeltas().length.

App Control

WorkflowWhat it doesSafety
App Window ControlResizes, maximizes, and repositions the DeltaWalker Classic window, which is useful for scripted layouts. It doesn’t read any files.Read-only

Appearance

The Workflow Gallery with category buttons, search field, and workflow cards

See Also

Última actualización el