Wednesday, 11 November 2009

Beyond Compare - File Comparison Tool

Sometimes it's the simplest activities that take the most time. If you're in the game of software development making changes in multiple versions of source files is a frequent and not very interesting activity. You'll often be working on your next major version then need to make a new minor version release either due to a problem in the current release or a need to support some new feature (like an unexpected tax rate change).

I'm showing my age here but in the past I've always used Windiff (in my Visual C++ 6 days). Windiff used to let me find out what the differences were between files. I could then merge file contents using a text editor. This process works but it was sometimes difficult to get files to match exactly as there were often extra spaces of line breaks.

Windiff disappeared from Visual Studio 2005 so more recently I've even restored to the old DOS FC command. I did have a quick play with Visual SourceSafe but the solution wasn't really flexible enough - often I want to compare and merge files without locking something down in a configuration management system.

However, I recently came across a package called Beyond Compare from Scooter Software. This package is absolutely fantastic and is now my second favourite software tool (after Visual Studio).

There are a number of good things about Beyond Compare.

Firstly it remembers folders you've compared in the past. This means you can do a new comparison and merge more easily the second time.

Secondly it lets you move updates from one file to another with a single mouse-click and shows you the results. Any extra/ missing whitespace differences are easily ignored. This makes merging versions take minutes rather than hours.

Thirdly, the software tool itself presents a trustworthy user interface. As you're doing a compare and merge with Beyond Compare, you can refresh the file comparison on the fly and check that things are absolutely identical. Knowing things are the same - bar the differences you want to keep - is vital to ongoing software development.

If merging files and versions of software is something you do regularly I'd recommend going to the Scooter Software site and taking a look at Beyond Compare.