Find revisions associated to a given file
Mathieu Clabaut
mathieu.clabaut at gmail.com
Mon Jul 9 05:32:56 CDT 2007
Ok...
I certainly can do a bruteforce search like:
hg log --template '{node}\n' myfile | while read ver; do hg cat -r $ver
myfile > /tmp/hgcat.$$; cmp /tmp/hgcat.$$ myreferencefile && echo "found
$ver"; done
But I wondered if there was a quicker mean by using indexes and hashes to
find the file...
I guess not, and I will stick to the aforementioned script.
Thank you for your advice.
-mathieu
On 7/9/07, Dustin Sallings <dustin at spy.net> wrote:
>
>
> On Jul 9, 2007, at 1:39, Mathieu Clabaut wrote:
>
> Imagine I've a mercurial repo and a file that once was part of a
> revision of this repo. Is there a (hopefully simple) mean to retrive the
> revision(s) associated to this file ?
>
>
> I don't know exactly what your goal is, but ``hg log [filename]'' will
> itemize all of the changesets that touched the file at that path. You can
> then use ``hg update'' or ``hg cat'' to see what things looked like on those
> revisions.
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://selenic.com/pipermail/mercurial/attachments/20070709/94bf0e88/attachment.htm
More information about the Mercurial
mailing list