Tech Tip: Meld for Visual Diffs
October 5th, 2009 by Lucas Vieites in
In diff tool speak, a visual diff tool is a GUI application. Meld is such a tool: a tool for displaying differences between files (and directories) and also for merging the differences. Meld is programmed in Python.
Meld can compare two or three files or folders and provides a simple way to merge differences. With just a double click you can copy the differences between the instances.
If you are comparing two directories you can double click on a file to open it and it's corresponding version in the second directory and view their differences. In the directory view you can choose to hide what might be trivial differences, such as binaries and backup files.
Meld also works with several versioning systems, such as CVS, SVN and Mercurial.
__________________________
| Attachment | Size |
|---|---|
| meld_tip.png | 117.08 KB |
Special Magazine Offer -- Free Gift with Subscription
Receive a free digital copy of Linux Journal's System Administration Special Edition as well as instant online access to current and past issues. CLICK HERE for offer
Linux Journal: delivering readers the advice and inspiration they need to get the most out of their Linux systems since 1994.
Subscribe now!
The Latest
Newsletter
Tech Tip Videos
- Nov-19-09
- Nov-04-09
Recently Popular
From the Magazine
December 2009, #188
If last month's Infrastrucuture issue was too "big" for you then try on this month's Embedded issue. Find out how to use Player for programming mobile robots, build a humidity controller for your root cellar, find out how to reduce the boot time of your embedded system, and if you're new to embedded systems find out the basics that go into one. You can also read about the Beagle Board, the Mesh Potato and a spate of other interestingly named items. And along with our regular columns don't miss our new monthly column: Economy Size Geek.
Delicious
Digg
StumbleUpon
Reddit
Facebook








xxdiff
On October 9th, 2009 Khalil Amar (not verified) says:
Let me quote flarg
"I recommend using xxdiff for visual file comparison, and our company uses Perforce, so we need a copy of the p4 binary for Linux"
source: http://www.flarg.com/dell-m60/dell-m60.html
:) xxdiff is good and offers the regretted SGI motif window look
Google for some xxdiff screenshots.
QBzr
On October 7th, 2009 Ulrik (not verified) says:
Since diffing is closely related to Version Control Systems, I would just like to mention QBzr, which has probably the most impressive diff-visualization I've seen so far. It has the alignment-features of Kompare, with the character-highlighting of Meld, but also adds some simple binaries-additions, mainly it shows images, so you can see if there are radical changes in those.
Highly recommended, if you run BZR (which is also highly recommended).
** meld vs winmerge ** And
On October 6th, 2009 asturbcn (not verified) says:
** meld vs winmerge **
And what about "WinMerge" (Windows Software)?
If it will hava a Linux version, I think I will prefer it versus meld.
Kompare does not seem an improvement
On October 5th, 2009 Nicola Larosa (not verified) says:
Kompare seems nicely done, the support for diff files is useful, and it's good that it only does two way diffs, without trying, and failing, to do three way ones, as Meld does.
However, it seems to miss an important feature that Meld and KDiff3 have: intra-line diff, that is, pinpointing what changed *inside* each line, instead of just highlighting flat blocks of lines.
Unless there's a way to do that by specifying a different diff program in the settings, but it's not mentioned in the help.
> it seems to miss an
On October 11th, 2009 Justin2 (not verified) says:
> it seems to miss an important feature that Meld and KDiff3
> have: intra-line diff, that is, pinpointing what changed
> *inside* each line
That's not true. What changed inside each line is pinpointed using (for example) "bold" letters.
I've checked it now with the latest Kubuntu, but you also can see it in
- http://lukeplant.me.uk/blogmedia/kompare_clipboard_diff.jpeg
- http://www.eloihr.net/linux/img/kompare.png
- http://files.barushev.net/tumblr/images/posts/2008-09/git-kompare.png
- and so on.
If you like
On October 5th, 2009 Anonymous (not verified) says:
If you like Meld, you'll LOVE Kompare.
Not Me
On October 5th, 2009 Mitch Frazier says:
Apologies, this tip is from Lucas, not from me, I forgot to change the author name when publishing it. Fixed now.
__________________________Mitch Frazier is an Associate Editor for Linux Journal and the Web Editor for linuxjournal.com.
Not really three way diff...
On October 5th, 2009 Nicola Larosa (not verified) says:
Meld is very nice, I use it frequently for moving diff chunks between pairs of files: but it is not really a viable three way diff tool.
One of the common usages of three way diff tools is a three way merge between a common ancestor branch and two diverged successors. In that case, it's vital having diff between all three pairs: A-B, B-C *and* A-C.
Meld gives you only the first two of them; other tools like kdiff3 also show the third one, albeit with a somewhat confusing usage of colors. Not easy doing better on that front though.
meld is great
On October 5th, 2009 Anonymous (not verified) says:
Meld is truly a wonderful tool! Thanks for the tip.
Post new comment