This is an archive of the discontinued Mercurial Phabricator instance.

remotenames: add three new revsets related to remotenames
ClosedPublic

Authored by pulkit on Feb 2 2018, 2:48 AM.

Details

Summary

This patch adds three new revsets 'remotenames', 'remotebookmarks' and
'remotebranches' which will return changesets which have remotenames,
remotebookmarks and remotebranches on them respectively.

The remotenames revset exist in hgremotenames extension and is moved from there
whereas rest of the two revsets are introduced in this patch.

hgremotenames: https://bitbucket.org/seanfarley/hgremotenames

Diff Detail

Repository
rHG Mercurial
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

pulkit created this revision.Feb 2 2018, 2:48 AM
yuja requested changes to this revision.Feb 2 2018, 8:03 AM
yuja added a subscriber: yuja.

These functions look quite similar. Perhaps we can extract a helper function
f(repo, subset, x, rtypes).

hgext/remotenames.py
37

Minor nit: use revsetlang instead.

265

Perhaps this should be:

@revsetpredicate('remotenames()')
def remotenamesrevset...
    """All changesets ...
270

Nit: _("remotenames takes no arguments").

279

cl.hasnode(n) instead of n in repo, which creates a changectx
object?

This revision now requires changes to proceed.Feb 2 2018, 8:03 AM
pulkit updated this revision to Diff 5161.Feb 2 2018, 12:47 PM
yuja accepted this revision.Feb 13 2018, 10:06 AM

Fixed help text and queued, thanks.

This revision is now accepted and ready to land.Feb 13 2018, 10:06 AM
This revision was automatically updated to reflect the committed changes.