KruSyncDir: Synchronize Directories

This function compares the left and the right panel directories and shows the difference between them. After selecting some options and the "compare" function you can synchronize the files and directories. One panel could be a FTP server. Don't forget the "compare by content" option if the file size stays equal. Choose Commands->Synchronize Directories or Ctrl+Y to start this feature.


KruSyncDir: Synchronize Directories

KruSyncDir: Synchronize Directories.


Procedure:

  1. Set the left and the right directory.

  2. Configure the optional file filter.

  3. Set the checkbox options: "Recurse subdirectories", "Follow symlinks", "Compare by content", "Ignore Date" and "Asymmetric".

  4. Click on the "Compare" button to compare the directories.

  5. By using the Show options, you can include/exclude particular filetypes. Those files, that are not in the list, will be untouched by synchronization.

  6. If needed you can change the "Task" operations determined by the Comparator with the right click menu.

  7. When you agree with the "Compare" results click on the "Synchronize" button to show the synchronize dialog.

  8. After selection the options of the Synchronizer, click on the "Start" button to start the synchronization process.

A detailed explanation of all the functions and buttons is described in the following text.

Comparator

Panel elements
  • "Left Directory": the left side base directory.

  • "Right Directory": the right side base directory.

  • "File Filter": filter the filenames at synchronizing. e.g. *.png selects only those files which name's ends with .png Directories will be listed if the directory name ends with .png or if the directory contains files which end with .png Multiple include/exclude example: '*.cpp *.h | *.moc.cpp' will include *.cpp *.h and exclude *.moc.cpp

  • "General filters": search for, containing text

  • "Advanced filters": size, date, ownership

Checkbox options
  • "Recurse subdirectories": the Synchronizer walks through on subdirectories when comparing.

  • "Follow symlinks": the Synchronizer follows the symbolic links to directories (not the files!).

  • "Compare by content": those files which size is equal will be compared by content as well.

  • "Ignore Date": Ignores the date information (useful for FTP, smb, archive, ... ) the date information is relevant only in the local file system.

  • "Asymmetric": The "Left Directory" is the target directory, the "Right Directory" is the source directory. This functions synchronizes the content of the left directory to the right directory.

    • Those files that exists only in the left side will be deleted.

    • Those ones that exists only in the right side will be copied to left.

    • Those files that considered to be equal will be untouched.

    • Those files that considered to be different will be copied to left.

    This function is useful if the date information is unusable, or to synchronize the left directory to the content of a fileserver (like a download). Or to make a backup from the right directory to left directory. NOTE: do NOT use this to option to synchronize a desktop and a notebook (e.g. files that exists only in the left side will be deleted!).

  • "Automatic Scrolling": It's for slow FTP servers, ... When the Synchronizer finished comparing a file, it puts the file into the end of the list at once and scrolls the window if it is necessary. It is important if you want to know what the Synchronizer is doing. If the FTP server is slow, the comparation of a directory may take a lot of time. By turning this option on, one can see that the comparator is "alive", but slow. For fast file systems, it can reduce the speed of comparing slightly.

When all the above things are done, click on the "Compare" button to compare the directories, the results are displayed in the "File List".

"File List"

The "File List" has the following columns: "Left name | Left size | Left time | Task | Right time | Right size | Right name".

Tasks (<=>)

This column will display the task that is planned for the Syncronizer.

  • ->: copy from the left side to the right side. For directories: mkdir in the right side.

  • =: the files are the same, don't do anything.

  • !=: the file is excluded, or the Synchronizer does not know what to do.

  • <-: copy from the right side to the left side. For directories: mkdir in the left side

  • DEL: delete files from the right side.

The tasks can be changed with the right click menu.

Show options

Here you can include/exclude particular filetypes. Those files, that are not in the list, will be untouched at synchronization.

  • ->: Enable/Disable the copy task from left to right.

  • =: Enable/Disable listing the equal files.

  • !=: Enable/Disable listing the excluded / "don't know what to do" files.

  • <-: Enable/Disable the copy task from right to left.

  • Trash: Enable/Disable the file deleting from the left side task.

  • Duplicates: Enable/Disable those files that exist on both side.

  • Singles: Enable/Disable those files that exist only on one side.

Action buttons
  • "Compare": compares the directories, the results are displayed in the File List.

  • "Stop": stops comparing.

  • "Synchronize": shows the synchronize dialog.

  • "Close": closes the Synchronizer window.

The Status line may contain
  • The number of scanned directories at comparing.

  • The filename at comparing by content (for big files).

  • The number of files in the list.

Right click menu on the File List

The right click menu is split up in three sections:

1. change the Task operations determined by the Comparator. Select one or multiple files. The change will be applied on the selection and not only on the right clicked item. If the selected item is a directory, the change will be applied on its files/subdirectories as well.

  • "Synchronise Directories": starts synchronization.

  • "Exclude": excludes a file/dir from synchronization ( task change to != ).

  • "Restore original operation": task change to the original result of comparator.

  • "Reverse direction": task change ( -> to <-, and <- to -> ).

  • "Copy from right to left": task change to <-.

  • "Copy from left to right": task change to ->.

  • "Delete ( left single )": task change to DEL.

2. change the selections

  • "Select items": Opens a dialog which allows you to select items. This is the Select Group dialog from the Mark menu.

  • "Unselect items": Opens a dialog which allows you to unselect items. This is the Unselect Group dialog from the Mark menu.

  • "Invert selection": Invert the selection status of all items.

3. others Note: the following operations work on the right-clicked file and not on the selection.

  • "View left file": starts viewer on the left file.

  • "View right file": starts viewer on the right file.

  • "Compare Files": starts the diff utility (e.g. Kompare) on the files.

Other buttons
  • "Profiles": If you have to synchronize often the same directories you can save the settings e.g. include files, exclude files, ... Press the 'profile' button, and you'll be able to add/ load / save / remove synchronizer profiles.

  • "Swap sides": swaps the File List.

Synchronize with kget

If you want to synchronize a local directory with an instable ftp server, kget is a much better solution than simple file copying. After comparing you may right click on the result list and select "Synchronize with kget" to execute the synchronization, after that the listed files will be downloaded with kget instead of krusader. Of course kget needs to be installed on your computer, otherwise it will not be available.

Synchronizer

After pressing the "Synchronize" button the synchronization dialog appears.

Check boxes

Here you confirm the copy and delete operations of the Synchronizer

  • "Right to left": copy X1 files ( Y1 bytes ) enable / disable the copy from right to left.

  • "Left to right": copy X2 files ( Y2 bytes ) enable / disable the copy from left to right.

  • "Left": delete X3 files ( Y3 bytes ) enable / disable the left side deleting.

  • "Confirm overwrites": By switching this option on, Krusader will show the "rename, skip, overwrite, skip all, overwrite all" dialog box, before overwriting the file.

Status labels
  • "Ready": A1/A2 files, B1/B2. This line is changed at synchronizing, showing that synchronizer finished with A1 files from A2 ( B1 bytes from B2 ).

  • "Progress bar": Shows the progress on the synchronization (based on bytes).

Action buttons
  • "Start": starts synchronization.

  • "Pause / Resume": pauses/resumes the synchronization process.

  • "Close": closes the synchronization dialog (and stops synchronization).