hg list fileset?

Martin Geisler martin at geisler.net
Fri Nov 22 05:34:14 CST 2013


Harvey Chapman <hchapman-hg at 3gfp.com> writes:

> I apologize if this is documented somewhere, but I can’t seem to
> figure out how to get a list of files using filesets and multiple
> revisions.
>
> Example: list all files in branch A but not in branch B. “hg help
> fllesets” says this is “A - B” but fails to list a command that would
> print that list.

I think you mis-read the help. The "x" and "y" placeholders in the help
text are other filesets. So you can do

  $ hg locate "set:exec() - grep(svn)"

to find executable files that does not contain the string "svn".

For comparing files in different revisions I would use 'hg manifest'
like this:

  $ diff <(hg manifest -r default) <(hg manifest -r stable)

If your shell doesn't understand the <(...) construct for creating a
pipe for the standard output, then you can always create two files using
normal direction.

-- 
Martin Geisler

Python expert for hire: http://careers.stackoverflow.com/mg
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 835 bytes
Desc: not available
URL: <http://selenic.com/pipermail/mercurial/attachments/20131122/e2bb5d37/attachment.pgp>


More information about the Mercurial mailing list