How do I find all files that have been "hg copy"'d

Gregory Szorc gregory.szorc at gmail.com
Sun May 1 18:44:50 UTC 2022


I don't believe revsets have a way to filter over copies explicitly. (That
would potentially be a useful feature!)

But templates do have a way to access just copies metadata.

You can do something like `hg log -T '{node|short} {join(file_copies, "
")}\n'` to print the copies in all changesets.

You can combine that with a revset query to limit which changesets are
printed. e.g. `hg log -r 'file("glob:mercurial/**")' -T ...`.

See `hg help templates` for more keywords related to copies and `hg help
revsets` for more ways to filter which changesets are displayed.

On Thu, Apr 28, 2022 at 8:23 PM John Carter via Mercurial <
mercurial at mercurial-scm.org> wrote:

> Related to my previous question...
>
> But if no solution for that is forthcoming... one solution would be to
> update to the changeset before the one that did the last "hg copy" and redo
> and prune that that changeset .
>
> But the question then becomes... how do  I find all hg copy's?
>
>
> ------------------------------
> This communication is confidential. We only send and receive email on the
> basis of the terms set out at www.taitcommunications.com/email_disclaimer
> ------------------------------
> _______________________________________________
> Mercurial mailing list
> Mercurial at mercurial-scm.org
> https://www.mercurial-scm.org/mailman/listinfo/mercurial
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.mercurial-scm.org/pipermail/mercurial/attachments/20220501/56bb1f93/attachment.html>


More information about the Mercurial mailing list