Application icon

Sync Files

This document describes version 3.x of the Sync File utilities.

In version 1, the Sync File utilities and the convert utilities were bundled in separate downloads.

Version 2 bundled the utilities together to take advantage of common helper actions. It also introduced an Exact Match scheme to attempt to match specific Permute 3 presets based on audio file settings.

Version 3 renames a number of the actions. When you update to version 3 by Yate's Action Updater, previously installed components which are no longer used will be removed. The Exact Match scheme introduced in version 2 was far too complicated. It has been replaced with a new Best Match scheme. Pre-existing best match profiles will be removed. Support has been added for XLD.

Version 3.1 introduces the ability to ignore files or folders when synching.

This suite contains actions to convert files via Permute 3 and XLD and to synchronize metadata between two copies of files.

If you are using the Permute 3 functionality of these actions please note that version 3.6.4 or later is required. Version 3.6.4 enabled the ability of Yate to specify the destination folder. You should read the Working With Permute 3 Presets topic to learn about matching presets based on audio properties.



Convert Files

Sync Files Utility - Overview

Sync Files Utility

Sync Files With Default Profile

Configuring Permute 3

Permute 3 Preset Information Display

Permute 3 Best Match

XLD Profile Information Display

Ignoring Files and Folders

Deleting Extra Folders

Content List, Requirements & History





Convert Files

This action is used to convert all selected files to a different file format using Permute 3 or XLD. Note that all metadata is preserved. The action only processes selected files.

If you have both Permute 3 and XLD on your Mac you will be prompted to select the converter you want to use. Once you select a converter or if you only have one installed, you will be presented with one of the two following panels:



Permute Panel

XLD Panel

For Permute 3 the items in the menu are enabled Permute 3 audio presets. The format of the panel displayed when Preset Info is selected is discussed Permute 3 Preset Information Display. Enabling the Best match checkbox will enable the ability to attempt to match the bit depth in an audio file to a preset. More information can be found in Permute 3 Best Match.

For XLD the items in the top area of the menu are the built in XLD presets. Potentially under these presets you will the names of XLD profiles that you have defined. These are discussed in XLD Presets and Profiles. The Profile Info button is only displayed if you have created XLD profiles. The format of the panel displayed is discussed in XLD Profile Information Display.

Once you have chosen a preset or profile the following panel will be displayed:



Source Panel

In Place places the new files in the same folder as each source file. When you select Folder you will be prompted to choose a folder to contain the produced files. You will then be presented with the following panel:



Overwrite Panel

This panel handles the disposition of preexisting files at the destination. It will not effect files loaded in Yate or files produced during the execution of the action. You can elect to overwrite pre-existing files at the destination or to leave them in place. Note that if you choose to overwrite the pre-existing files at the destination, they will be moved to the trash or permanently deleted before a conversion takes place.

You can then choose what to do with the source files.



Delete Source Panel

You can delete source files or leave them in place. An attempt is first made to delete files by moving them to the trash. If the files cannot be moved to the trash they will be permanently deleted. Source files will only be deleted after a successful conversion.

At this point all configuration has been completed. You will be presented with the choices that you have made.



Preview Panel

You can select Convert Files to start the conversion process or Restart to restart the configuration process. If you decide to convert, progress will be displayed on the status bar. When the conversion process is completed the following panel will be displayed:



Convert Done Panel

Note that the log file is overwritten after each conversion. The log file displays the steps that were performed for each audio file and will contain the final name of each produced file. A produced file's name might have a duplicate indicator appended if the source filename was already used.

After a conversion deleted files will be removed from the main window and newly created files will be loaded and selected. With the exception of the encoder related fields, all metadata will have been copied from the source files to the produced files.



Back to top of page





Sync Files Utility - Overview

Many users have two or more activate copies of their audio files. Sometimes the copy is a one-to-one copy and sometimes the audio files are encoded differently.

These actions provide a means of syncing any changes to the metadata in the originals to a copy. The sync trigger is simple ... the two files have different modification dates. When a sync occurs, metadata is copied from the source file to the destination file.

Note that files or entire folders can be marked as never sync. See Ignoring Files and Folders for more information.

Note that the process does not mirror the data ... they only ensure that the destination contains everything at the source.

These actions only work if filenames and folder structures under the roots are exactly the same. For example if you are syncing /Users/Me/Music to /Volumes/Music/Copy, the following files are a match:

/Users/Me/Music/John Doe/His Best/song.mp3
/Volumes/Music/Copy/John Doe/His Best/song.???

The filename extension on the second file is described as ??? as how files get matched is controlled by the actions.

Two user facing actions are supplied:

Sync Files Utility
This is the main action which provides all the configurability.

Sync Files With Default Profile
The Sync Files Utility lets you create different profiles for different processes. This action runs the default profile without presenting any configuration options.

These actions let you optionally copy or convert the source files when the file at the destination is missing. When conversion is required, Permute 3 is used. Permute 3's automation via Yate was jointly designed. If you do not have Permute 3 on your Mac, the options to convert files will not be presented. These actions require Permute 3.6.4 or later.



Back to top of page





Sync Files Utility

The first time you run this action you will be immediately prompted to create a profile.



New Profile Image

After entering a profile name and continuing, you will be presented with a panel requesting you to choose the root source folder. This is the folder which will be passed to the Batch Processor. All files in or under the chosen folder will be processed. Cancelling will restart the process.

Once you've chosen the source folder you will be prompted to select a root destination folder. This is the folder containing the files to be modified, if required. After selecting the destination folder, you will be presented with the following panel:



Source Extension Choice Image

If you want to sync all encountered audio files leave the field empty. Alternately you can successively choose a file type from the picker menu. Select Done when you are finished specifying the source audio types. If you make a mistake select Clear Selections from the menu. When done you will be presented with:



Source Extension Choice Image

The popup menu displays the audio filename extensions supported by Yate. You only have to choose something from the picker control's menu if you are synching to different audio file types than in the source. If your libraries are copies nothing need be chosen. However if you are syncing from FLAC files to AIFF files, you must choose the appropriate destination extension (AIFF). If you intend to use Permute 3 or XLD to produce missing files, you must specify a filename extension on this panel.

If you do not have Permute 3 or XLD on your Mac you will be presented with the following panel.



Copy Files Image

You must decide if you want to attempt to create missing files by copying them if the destination requirements will be met.

If you have Permute 3 or XLD on your system you will be presented with a variant of the following panel.




Copy Files Image

You must decide how you want to handle missing files. The XLD and Permute 3 buttons are only displayed if the associated applications are on your Mac. Select a converter or Copy Only to attempt to create missing files by copying them if the destination requirements will be met. Select Ignore to never create missing files.



If you selected Permute 3 you will see the following panel.



Choose Permute 3 Preset


You must specify which active Permute 3 preset to use. The menu will display the name of all enabled Premute 3 audio presets. Enabling the Best match checkbox will enable the ability to attempt to match the bit depth in an audio file to a preset. More information can be found in Permute 3 Best Match.



If you selected XLD you will see the following panel.



Choose Permute 3 Preset


Items above the separator line are the names of XLD presets. Items below the separator line, (if any), are the names of XLD profiles.

You now have to decide what to do with non audio files and folders in each source folder containing audio files.



Non Audio Image

Your choices are as follows:

Never
Non audio files and folders are never copied to the destination.

New Folder
If the destination folder corresponding to the source folder containing audio files currently being processed by the batch processor had to be created, all non audio folders and contained folders which do not have an audio file as a descendent, will be copied. Note that the copied folder completely overwrites a preexisting folder of the same name.

On Changes
Changes can be: creating the destination folder; copying a source file; converting a source file or synchronizing metadata to a file in the destination folder.

Always
An attempt is made to always copy the non audio files and folders.

Similarly you can opt to set the icon of the destination folder.



Non Audio Image

The choices are the same as with non audio files.

Last but not least you can elect to search for folders on the destination which are not in the source and to optionally delete them.



Delet Folders

Congratulations, at this point you will have created your first profile. You will be presented with the next panel which will be displayed whenever you next start the action:



Main Panel Image

The name of the profile you just created will be displayed. When a profile name is displayed in the text field there are a number of functions you can perform. The most obvious is that you can run the process via the Run button. This will start the Batch Processor to do the work. If you have not enabled Preferences - Actions - Enable Batch Processor auto start from Stop Action and Run Batch Processsor, you will be presented with the Batch Processor's ready to go panel and you will have to hit Start. If the option is enabled, the Batch Processor will simply start.

When this panel is displayed, you can perform various functions on the profile named in the text field. The menu displays functions at the top and the names of your defined profiles at the bottom. A brief description of each function follows:

Display Profile Information
The parameters you set for the profile named in the text field will be displayed. You can choose to run the profile from the displayed panel or go back to the main panel.

Create New Profile
You will be stepped through the new profile process for a profile.

Remove Profile
The profile specified in the text field will be deleted.

Set Profile as Default
The profile specified in the text field will become the default profile. This profile is displayed in the menu preceded by a checkmark. The default profile is the profile used when the Sync Files With Default Profile action is run.

Unmark Default Profile
This function ignores the profile name in the text field. After executing this function there will be no default profile.

Validate Profile Information
A test will be made to ensure that the information contained in the named profile is correct. Note that this is done automatically whenever a profile is run. If everything is okay, you will be given the option to run the profile or to return back to the main panel.

Active Permute 3 Audio Presets
This is only displayed if Permute 3 is available. See Permute 3 Preset Information Display for more information.

XLD Profiles
This is only displayed if XLD is available. See XLD Profile Information Display for more information.

A profile name
When a profile name is selected it is copied to the main panel's text field.


Back to top of page





Sync Files With Default Profile

If a default profile has been designed via the Sync Files Utility action and the profile information can be validated, the batch processor will be launched to run the profile.



Back to top of page





Configuring Permute 3

It is recommended that you make the following Permute 3 - Preferences - General settings:

These actions can interact with any enabled Permute 3 audio preset. Presets are enabled, created, duplicated and edited in Permute 3 - Preferences - Presets. Changes are not applied until Permute 3 - Preferences is closed.

Note that Permute 3's AAC preset does not refer to AAC in m4a files! More than likely these are the out of the box presets that you should be working with: AIFF, Apple Lossless, FLAC, M4A, MP3, Ogg (Audio) and WAV.


Back to top of page





Permute 3 Preset Information Display

Each item in the displayed panel describes a Permute 3 preset. The preset's settings are displayed. The first setting (and possible only setting) is the internal class name for the type of audio file being produced. If a C item is displayed, the value is Channels setting (0 for As Source). If an S item is displayed, the value is the Sample Rate setting (0 for Same as Source). If a B item is displayed, the value is the Sample Bits setting.




Permute 3 Preset Image

Back to top of page





Permute 3 Best Match

Permute 3 presets can mark the Channels and Sample Rate settings to match the source. However, there is no equivalent setting for the Sample Bits setting. When choosing a Permute preset you can also elect to enable Best match. When Best match is enabled the preset used is determined as follows:


Back to top of page





XLD Profile Information Display

This panel displays names of XLD profiles and their associated produced filename extension.




XLF Profiles Image

Back to top of page





Ignoring Files and Folders

When using the Sync Files or Sync Files With Default Profile actions you can elect to always ignore specific files or entire folders. A UDTI named NOSYNC or a custom field of the same name (case insensitive) is examined.

If any file in a folder has a NOSYNC value of 2, the entire folder is ignored. Any files which has a NOSYNC value of 1 are ignored. Any other value of NOSYNC is ignored.

If you wish to create a custom field, configure it as follows in Preferences - General - Custom Fields:



NOSYNC Custom Field


Back to top of page





Deleting Extra Files

If the Sync Files action is processing a profile where the Search for extra folders option is enabled, the source and destination folder trees will be compared. If extra folders, (folders in the destination but not in the source), are found they will be identified in a table.

You can select any folders that you want to delete. The context menu has items to select all or no folders for deletion.

Note that the selection of some folders may be redundant. For example if the following folders are displayed:

Album 1
Album 1/Disc 1
Album 1/Disc 2

Selecting Album 1 will delete its contained folders even if they are not selected.

Warning: This function deletes folders. It does not move them to the trash!



Back to top of page





Content List, Requirements & History


Content List:

Action : Convert Files

Action : Sync Files Utility

Action : Sync Files With Default Profile

Action : Sync Files - Batch Processor

Action : Helper: Update Profile

Action : Display Active Permute Presets

Action : Display XLD Profiles

Action : Helper: Extension for Permute 3 Preset

Action : Helper: Extract Permute 3 Presets

Action : Helper: Read XLD Profile Names

Action : Helper: Extract Profile Metadata

Action : Helper: Validate Profile

Action : Helper: Run Batch Processor

Action : Helper: Convert Engine

Action : Helper: Process Best Match

Action : Helper: Walk Folder

Rename Template: Variable 12

Replacement Set: HTML

Requirements:

Yate v6.8

History:

2021-05-18  v1.0 First release.

2021-06-24  v2.0 Combined PerMute 3 and Sync Files in this bundle. New Preset handling. Released to the Preview List.

2021-07-04  v2.1 Support for Permute 3 installed by SetApp. Released to the Preview List.

2021-07-12  v2.2 Changes for Yate v6.6. Released to the Preview List.

2021-07-17  v2.3 Various cosmetic changes.

2021-07-18  v2.4 Files passed to Permute 3 which contained special characters were not escaped properly.

2021-07-20  v2.5 Accumulated changes for Yate v6.6.

2021-07-24  v2.6 Minor adjustments.

2021-07-26  v2.7 Patched Helper: Is Permute 3 Preset Active.

2021-08-10  v3.0 Introduced XLD support. Replaced Exact Match support with Best Match scheme. Many other changes.

2021-12-04  v4.0 Added NOSYNC support. Cleaned up UI with new features in Yate v6.7.

2022-01-02  v4.1 Fixed issue with the display of XLD profiles.

Download


Back to Yate Resources