views:

136

answers:

2

For a given file in a Mercurial repository, how can you see the revision history?

And how can you diff two revisions of the file?

Ideally doing all this with visual tools (we use ExamDiff to do some other diffs).

I'd say this is basic source control functionality but I can't seem to figure out how to do this with Mercurial.

+3  A: 
hg log file

hg diff -r 10 -r 20 file
zerkms
Perfect.. Works with ExamDiff too: `hg examdiff -r 10 -r 20 file`
Marcus
A: 

The hgk extension gives you hg view file command that shows a visual history, from which you can diff/vdiff arbitrary pair of revisions.

TortoiseHg gives you hgtk log file command that does the same thing but looks better.

Geoffrey Zheng