8. Comparing Folders

The Folder compare window displays all of the files and subfolders compared in a sortable list view. Files and subfolders may be synchronized by copying or deleting, and actions may be performed on multiple items simultaneously. The columns displayed may be changed and reordered.

Folder comparison has two different modes. The mode is selected in the Open dialog with the "Include Subfolders"-checkbox.

WinMerge 2.4 is finally capable to compare large binary files. There is new Compare by Quick Contents -compare method which makes it possible. For more information about different compare methods see Options & configuration -chapter. In WinMerge 2.4 all files bigger than 4 MB (megabytes) are automatically compared with Compare by Quick Contents -method. Downsides for this method are that linefilters do not work and there is no difference counts information in folder compare UI. For most cases this should not matter since so big files usually are binary files.

For advanced users: If that limit does not feel good (you have lots of big text files) it can be changed via registry value: HKEY_CURRENT_USER\Software\Thingamahoochie\WinMerge\Settings\QuickMethodLimit. As usual be careful when changing values directly to registry!

8.1. Folder Compare Statepane

During folder compare proceeds, following statepane is shown:

Statepane shows several kinds of status and progress information. At the top there are numbers of already compared items per category. So this compare has found 107 similar text files so far. Bottom of pane is progressbar. And left to progressbar are numbers of items compared and total items found to compare. So this compare has compared 203 items from total of 312 items.

Important

Progressbar is for item counts. As there usually are different sized files in compare it does not directly map to time used/remaining. So 50/100 items does not strictly mean compare is in half by time used.

Folder compare can be stopped by selecting "Stop"-button and results for files and folders compared so far are shown. After folder compare finishes, "Stop" button text is changed to "Press any key". Now statepane can be closed by selecting that button or pressing any key from keyboard.

Statepane can be opened from View-menu again if needed. Statepane always shows current status of compare so it can be used to verify there are no different files left to handle.

Tip

Enable option Close Compare statepane automatically and statepane closes automatically after compare is ready.

8.2. Compare Results

Files and folders are compared and divided into several categories:

Identical text files
Differing text files
Identical binary files
Differing binary files
Left-only folders
Right-only folders
Left-only files
Right-only files
Skipped directories (filtered out)
Skipped files (filtered out)
Items that couldn't be compared. This usually happens when other program has locked the file.

8.3. Selecting Items to Show

In "View" menu there are several choices for selecting which categories listed above to show/hide.

8.4. Columns in Folder Compare

By default these columns are visible:

Following columns are available through "Customize Columns"-dialog:

8.5. Browsing Folders

Browsing folders is only possible when subfolders are not included to compare (Include Subfolders checkbox is not checked in Open-dialog). Parent folders (".."-item) and subfolders existing in both sides can be compared by double-clicking with mouse over them or selecting them and pressing Enter.

Parent folder can be opened if it is not same directory. These two icons indicate if parent folder can be opened:

Parent folder can be opened.
Parent folder cannot be opened. It probably is same directory for both sides.

8.6. Navigation in Folder Compare

In addition moving selection using mouse or keyboard, also Merge-menu navigation commands, toolbar buttons and shortcut keys can be used. For example "Next diff" finds next different file and selects it.

Note

Unique files and folders are considered as different ones.

Multiple files/folders can be selected. However not all operations are possible with multi-selection.

8.7. File Operations in Folder Compare

8.7.1. Copying, moving and deleting

Folder compare allows user to copy and delete files and folders. File operations are available through context menu (right-click with mouse). Also files can be opened to associated program or into external editor.

In file operation menu, there are one or two numbers shown, depending on files/folders selected. If there is one number shown, for example "Copy/Left to... (5)" that means there is 5 items selected, and all items can be copied. But if there is two numbers shown, for example "Copy/Left to... (3 of 5)", that means there are 5 items selected but only 3 items can be copied.

Most common operation is copying files from side to side. File can be copied from side to side using Merge-menu items, toolbar buttons and context menu. If multiple files are selected, or file to overwrite is read-only, confirmation dialog is shown.

Sometimes it is useful to copy certain files and/or directories to another directory instead of another compared directory. This can be done selecting "Copy/Left to..." or "Copy/Right to..." items.

Another file/folder operation is deleting. Items in another or both sides can be deleted. There is "Send deleted files into Recycle Bin" option in system options (See Options & Configuration -chapter). It is highly recommended to keep that option enabled so deletion can be undone if accidents happen. Note however recycle bin does not help if its disabled from Windows settings.

Moving is just shortcut for copy + delete.

Warning

File/folder deletion cannot be undone if Recycle Bin is not used!

8.7.2. Opening files

There are three items in Open-menus:

  • With Registered Application : Opens file with application registered handling filetype for Windows, if there is one.

  • With External Editor : Open with external editor. Default editor can be selected from options, Notepad is used by default.

  • With ... : Opens "Open With..." dialog asking from user with which application files should be opened.

Tip

Selecting With Registered Application when folder is selected usually opens that folder into new Explorer window.

8.7.3. Archiving

Zip-menu in directory compare context menu allows adding selected items to archive file.

Note

Archive support requires that 7-Zip plugin is installed to system.

Zip-submenumenu has four items:

  • Left... : Adds left-side files and folders (recursively) to the archive file

  • Right... : Adds right-side files and folders (recursively) to the archive file

  • Both... : Adds files and folders (recursively) from both sides to the archive file. Because filenames are same, files must be put to subfolders inside archive. Left-side files are put to subfolder Original/ and right-side files are put to subfolder Altered/.

  • Differences... : This is like above Both, but this item adds only different files (including unique files) from both sides.

After selecting one of Zip-menu items dialog pops up asking filename and archive type from user. WinMerge cannot add files to existing archive files but it always creates new archive file.

Tip

WinMerge looks for subfolders Original/ and Altered/ in archive files. If archive file contains these subfolders and same filename is given to both sides WinMerge compares contents of those two folders.

If directory compare shows contents of archive files WinMerge updates changes done to files in file compare into original archive file. But WinMerge does not update archive contents for files added/deleted/copied. User can create a new archive file using above menuitems instead.

8.8. Copying Path- or Filenames

In context menu there are items for copying selected items' paths or filenames to clipboard. This feature makes it easy so get list of changed files, for changelogs etc.

8.9. Customising Folder Compare

There are many ways to customize folder compare:

8.10. Protecting Folders / Read-only Folders

If user wants to protect one or both sides from changes, user can set them to read-only from File-menu.

Important

Setting read-only protects files and folders in current compare view only.

Protected status is inherited to opened files from directory compare. If user compares two folders, sets another to protected and opens two files for comparing, file opened from protected side has protection set too.

Protection status is shown in statusbar, there are own panes for left and right side.

8.11. Hiding Items

Selected items can be hidden from view using context menu item Hide Items. Hidden items are not shown until next refresh is done. All hidden items can be re-shown selecting View->Show Hidden Items.

Hiding items is handy to remove already handled items from the view. So when you have merged files, use context menu item to hide them. It is a lot easier to see what items are left to merge. Get used to it! It saves your time!

8.12. Refreshing Only Selected Items

Full refresh of large folders can take a long time. In 2.2 and earlier versions of WinMerge user always had to do full refresh after editing files outside WinMerge. WinMerge 2.4 can refresh just selected items. Select Refresh from context menu.