DirSync3 — Synchronize Directories

Here you can discuss about your favorite plug-in.
pepak
Posts: 446
Joined: Sun 13 Jul, 2008 11:18
Has thanked: 10 times
Been thanked: 25 times

DirSync — Synchronize Directories

Post by pepak »

Latest post of the previous page:

Presumably because I forgot about the older one when announcing the new one. Or something. No reasonable reason that I am aware of.

pepak
Posts: 446
Joined: Sun 13 Jul, 2008 11:18
Has thanked: 10 times
Been thanked: 25 times

DirSync — Synchronize Directories

Post by pepak »

Version 0.96 http://www.pepak.net/files/far/dirsync3-0.96.zip
(seems that I forgot to announce this version back in October 2014)
  • Fixed the incorrect behavior of "selected items only" option: If a file was selected on one panel only, it would be marked as missing on the other panel. For correct function, you needed to select the file on both panels. Now it suffices to select the file on one panel.
  • Fixed display of "..\*" difference when comparing a root of some drive with a non-root directory.
  • Display a total progress bar in the tray area for synchronization. The progress is based on the number of processed lines compared to the number of all lines, not on the size of the respective files or directories; this is done to prevent unnecessary slow calculations.

pepak
Posts: 446
Joined: Sun 13 Jul, 2008 11:18
Has thanked: 10 times
Been thanked: 25 times

DirSync — Synchronize Directories

Post by pepak »

Version 0.97 binaries, source code
  • Changed the way "Remember" checkbox works: Now it is directory-specific, i.e., it only works for a given directory and its subdirectories. For example, suppose that you are synchronizing drives C:\ (source) and D:\ (destination). When syncing file C:\SomeDir\a.txt, an overwrite confirmation dialog pops up. You want to overwrite the destination file, as well as the thousand other files in the C:\SomeDir directory, but you don't want to overwrite files in C:\Windows without confirmations. In the previous versions, you were out of luck - you could either remember "Overwrite" for all files or for no files. In 0.97, you can remember "Overwrite" for directory "C:\SomeDir" and its subdirectories, but keep the default "Ask me" for all other directories. If you wanted to remember "Overwrite" for all directories, you could simply empty the "remember directory" editbox, or perhaps change it to "C:\".

    As long as the "Remember" checkbox is focused, you can use the following keyboard shortcuts:

    Backspace ... Remove the last path element from the directory (i.e., remember the selection for the parent directory of the currently selected directory).
    Delete ...... Set the directory to en empty string (i.e. remember the selection for all directories).
    F5 .......... Reset the directory to its original value, e.g. if you mistakenly press Backspace or Delete, undo the change.

    The original behavior (with the same "Remember" setting for all files and directories) can be restored by activating the "Global remember" option in the Synchronize Options dialog; the default value can be set in the Plugin Options.
  • While adding the previous feature, I also fixed some illogical behavior of the "Remember" checkbox. E.g., if you confirmed that you wanted to delete a directory, the plugin would still ask for confirmation before deleting files within that directory.
  • Removed the options "Show report of found differences" and "Display a message if no differences were found". Both of these date back to the days when the plugin was based on Advanced Compare and don't really make much sense as far as DirSync is concerned - they should be enabled all the time.
  • Added option "Select differences on both panels". When unchecked (the default state), differences are only marked on that panel which contains the newer version (which is useful if you intend to do something other than just the synchronization with these files). When checked, differences are marked on both panels, just like it used to work with the Advanced Compare plugin.
  • The synchronization editor got a new functionality to locate the next difference of a given type. Currently available are:

    ALT+F5 ... Locate file missing on the left, file older on the left, or files different but of the same age.
    ALT+F6 ... Locate file missing on the right, file older on the right, or files different but of the same age.

    These functions are also available from the plugin menu, to facilitate their re-mapping to different keys through a macro.
  • The plugin no longer appears when F11 is pressed in a dialog.

User avatar
Wave
Posts: 1771
Joined: Thu 04 Aug, 2005 18:47
Has thanked: 4 times
Been thanked: 16 times

DirSync — Synchronize Directories

Post by Wave »

I test ver 0.97 far3 x86 on far 4400. Run plugin, see editor with files and folders, which can copy-move-delete to left or to right. Run plugin via menu to change direction of operations. See two messageboxes:

Incorrect or damaged …\DirSync\DirSyncRus.lng
Message 137 not found

and

Incorrect or damaged …\Utils\DirSync\DirSyncRus.lng
Message 138 not found
Пользуюсь ФАРом больше 20 лет © собирательный.

pepak
Posts: 446
Joined: Sun 13 Jul, 2008 11:18
Has thanked: 10 times
Been thanked: 25 times

DirSync — Synchronize Directories

Post by pepak »

Yep, I am an idiot - I forgot to add the last two language strings to the russian and spanish language file:

Code: Select all

"Find next older/missing on the l&eft"
"Find next older/missing on the r&ight"
I have by now updated the original archive on the web, so if you just redownload it, everything should work just fine.

User avatar
Wave
Posts: 1771
Joined: Thu 04 Aug, 2005 18:47
Has thanked: 4 times
Been thanked: 16 times

DirSync — Synchronize Directories

Post by Wave »

Thanks!
Пользуюсь ФАРом больше 20 лет © собирательный.

User avatar
John Doe
Бюрократ
Posts: 12652
Joined: Wed 27 Apr, 2005 20:42
Has thanked: 35 times
Been thanked: 270 times

DirSync — Synchronize Directories

Post by John Doe »


pepak
Posts: 446
Joined: Sun 13 Jul, 2008 11:18
Has thanked: 10 times
Been thanked: 25 times

DirSync — Synchronize Directories

Post by pepak »

Back in 2009 I wanted a synchronization plugin which didn't exist at the time. So I took the sources from FAR 1's Advanced Compare and modified them in several places to get the functionality I wanted. The result was pepak @ DirSync. Maximus5 took pepak @ DirSync, updated it for FAR 2 compatibility and released it as Maximus5 @ DirSync. Eventually he implemented some new features and also provided a MacroLib script for better control of the editor with synchronization info. But for some reason I didn't like his script and rewrote it as macro pepak @ DirSync.

Eventually I decided to reimplement the whole plugin from scratch. The result is what we discuss in this thread.

User avatar
John Doe
Бюрократ
Posts: 12652
Joined: Wed 27 Apr, 2005 20:42
Has thanked: 35 times
Been thanked: 270 times

DirSync — Synchronize Directories

Post by John Doe »

pepak wrote: rewrote it as macro pepak @ DirSync.
Is it for new or for old plugin?
pepak wrote: the whole plugin from scratch.
I suggest you to add this story and links to corresponding topic title posts (and plugin docs), and change new plugin name to somewhat like http://forum.farmanager.com/viewtopic.php?f=34&t=9726 (feel free to edit).

pepak
Posts: 446
Joined: Sun 13 Jul, 2008 11:18
Has thanked: 10 times
Been thanked: 25 times

DirSync — Synchronize Directories

Post by pepak »

John Doe wrote:
pepak wrote: rewrote it as macro pepak @ DirSync.
Is it for new or for old plugin?
It is for Maximus5's plugin. It is no longer relevant for my current plugin.
pepak wrote: the whole plugin from scratch.
I suggest you to add this story and links to corresponding topic title posts (and plugin docs), and change new plugin name to somewhat like http://forum.farmanager.com/viewtopic.php?f=34&t=9726 (feel free to edit).
I guess. This will be particularly interesting to handle with the PlugRing.

User avatar
John Doe
Бюрократ
Posts: 12652
Joined: Wed 27 Apr, 2005 20:42
Has thanked: 35 times
Been thanked: 270 times

DirSync — Synchronize Directories

Post by John Doe »

pepak wrote: t is for Maximus5's plugin. It is no longer relevant for my current plugin.
Ok, I just moved it to corresponding topic (russian).
pepak wrote: This will be particularly interesting to handle with the PlugRing.
Nothing special.
But please make sure that new plugin has different GUID.

pepak
Posts: 446
Joined: Sun 13 Jul, 2008 11:18
Has thanked: 10 times
Been thanked: 25 times

DirSync — Synchronize Directories

Post by pepak »

John Doe wrote:But please make sure that new plugin has different GUID.
I already did. I didn't keep any of the old code, including GUIDs.

User avatar
John Doe
Бюрократ
Posts: 12652
Joined: Wed 27 Apr, 2005 20:42
Has thanked: 35 times
Been thanked: 270 times

DirSync — Synchronize Directories

Post by John Doe »

Ok. I've just added links to russian announce: http://forum.farmanager.com/viewtopic.p ... 506#p82506

Please update your old topic yourself (add link to new plugin and hide pictures into

pepak
Posts: 446
Joined: Sun 13 Jul, 2008 11:18
Has thanked: 10 times
Been thanked: 25 times

DirSync3 — Synchronize Directories

Post by pepak »

Version 1.01
  • Fixed very long filenames from version v0.90 - the feature did not actually work.
  • The user's decision for the "delete directory" operation (Delete/Skip) is now applied to files within that directory, too.
  • Fixed incorrect redraw after pressing ESC during the synchronization phase.
  • When synchronizing directories, copy also file attributes (read-only, hidden etc.).
  • During the initial scan for differences, show the indeterminate progress status in the FAR Manager icon. It will get removed when the scan completes.
  • Refresh the panels when synchronization completes.
Download

User avatar
Dennis_Moore
Posts: 287
Joined: Tue 03 Mar, 2015 19:54
Location: Kiev
Has thanked: 6 times
Been thanked: 14 times

DirSync3 — Synchronize Directories

Post by Dennis_Moore »

Hello pepak! It seems that Alt+F3 in editor did not work correctly. Here is what i see after pressing that hotkey:

Image

My configuration: FAR3 b4898, DirSync 1.1.0.558, Windows 7 SP1 + Updates

pepak
Posts: 446
Joined: Sun 13 Jul, 2008 11:18
Has thanked: 10 times
Been thanked: 25 times

DirSync3 — Synchronize Directories

Post by pepak »

That's a problem of your configuration. DirSync3 does not perform side-by-side comparison, it calls a program (e.g. WinMerge) to do that. You need to set this program up in plugin options. Then the functionality will work just fine.

Post Reply

Return to “General Plug-In Discussions”