The Synchronize tool lets you synchronize the contents of two folders. The folders involved can be any location that Opus can access - local drives, archives, network shares or even on an FTP site. You can specify the criteria used to determine whether a file should be copied or not, and you can choose whether synchronization is one-way or two-way. To access the Synchronize tool, select the Synchronize command from the Tools menu.

The Synchronize tool is displayed in the Utility Panel at the bottom of the Lister.

Synchronize is a two-step process:

Comparison mode

The left half of the panel contains options that control the comparison stage.

One-way copy mode options

In one-way copy mode, the comparison methods you can choose are:

Other options available in one-way copy mode:

General comparison options

Other options which control the comparison stage in both one-way and two-way mode:

Synchronize location

The fields on the right of the panel determine which folders are synchronized. Depending on the Synchronize left-to-right option, these fields are either called Source and Destination, or Left and Right.

When the panel opens the location fields will default to the locations in the current source and destination file displays.

Each field has a "link" button which lets you link it to the current location in the Lister. When the field is linked it will update automatically whenever you navigate to a new location - this lets you use the Lister for navigation without having to update the location fields manually.

You can use the Browse buttons for each field to select a different location, or type the path in manually.

The Swap button to the right of the location fields swaps the values of the fields around.

The options below the location fields are:

Excluding locations

The Exclude field lets you specify folders that are excluded from the synchronize operation.

This field lets you enter one or more paths, or filenames, or wildcard patterns. Any folders that match will be excluded from the operation. In the screenshot above, any folders called .svn and .github would be excluded from the synchronize.

The two options in the drop-down let you automatically exclude hidden folders and system folders from the operation.

Performing the comparison

Synchronization is a two-stage process - comparison followed by synchronization. The comparison stage is when Opus compares the source and destination folders and works out what needs to be copied and/or deleted.

After setting your desired options, click the Compare button in the bottom-right corner of the panel to begin the comparison. The procedure Opus follows when you do this is:

  1. If the Lister is not currently in dual-display mode, a second file display will be opened.
  2. The source and destination folders will be read into the source and destination file displays (if they're not already showing them).
  3. Both file displays will be put into checkbox mode (actually a special variant of checkbox mode that's only used for Synchronize and the Duplicate File Finder).
  4. If the Synchronize sub-folder contents option is on, both file displays will be put into Flat View (Grouped) mode, and Opus will read the contents of all sub-folders.
  5. The source and destination folders will be compared based on the options chosen. This step can take some time depending on the size of the folders involved.
  6. The files and folders selected for synchronization will be indicated as such with a series of glyphs in their checkboxes to indicate what action will be taken.
  7. If the Hide unaffected files option is on, any files not selected for synchronization will be removed from the display.
  8. The results of the comparison will be summarised in a dialog box.
Comparison results

 

At this point, you can click the Synchronize button to begin the synchronization. If however you want to check the file list first to see exactly what's going to happen, or you want to make changes to the files selected for synchronization or to the comparison options, you can click the Close button to return to the Lister. You'll then see the following kind of display in the file list.

Reviewing and changing synchronize actions


 

This screenshot corresponds to a one-way copy comparison. The files that have been selected for synchronization are marked with a series of glyphs that indicate the recommended action (copy, delete or no action). You can make changes to the synchronize action for a file or folder by simply clicking on its checkbox - Opus will cycle through the various actions available every time you click.

If you are dealing with a large number of files, you may wish to remove from the display those that you have marked to not be synchronized. To do this, right-click the background of the file display and choose the Hide unaffected items command from the context menu. Any files that are not marked as either copy or delete will be removed from the display. You can redisplay the hidden files with the Reveal hidden items command.

Comparison errors

The results summary dialog will also inform you of any errors encountered during the comparison stage. An error can arise if a file on one side of the comparison has the same name as a folder on the other side.

If conflicts arise, the files and folders concerned will be skipped by the synchronization process - but if you want to investigate further and rectify the issue, you can click the Conflicts which appears in the summary dialog. This will return you to the Lister and highlight the conflicting items for you.

Performing the synchronize

Once you've verified (and possibly modified) the synchronize actions, you can begin the synchronization by clicking the Synchronize button in the bottom-right corner of the panel.

If you change any of the options at this point the Synchronize button will be disabled and you will need to re-run the comparison by clicking Compare again before you can proceed with the synchronization. Once the synchronization stage begins, it proceeds as more or less an automated operation. The progress dialog will step through the various parts of the synchronization (copy from source to destination, copy from destination to source, delete from destination) as the operation progresses.