D5940: uncommit: add --allowdirtywcopy when possibly hiding data (issue5977)

pulkit (Pulkit Goyal) phabricator at mercurial-scm.org
Fri Feb 15 14:11:51 EST 2019


pulkit added a comment.


  Your current patch is doing more than one thing. Let's split this up and make one patch do one thing.

INLINE COMMENTS

> uncommit.py:168
>  
> +        if old.p2():
> +            raise error.Abort(_("outstanding uncommitted merge"))

this merits a different patch and tests of it's own.

> uncommit.py:170
> +            raise error.Abort(_("outstanding uncommitted merge"))
> +        if not opts.get('force'):
> +            cmdutil.bailifchanged(repo, hint=_('use -f to force'))

this should also consider checking the config `experimental.uncommitondirtywdir`.

> rewriteutil.py:43
>          raise error.Abort(_("cannot %s changeset with children") % action)
> +    if merge and any(repo[r].p2() for r in revs):
> +        msg = _("cannot %s merge changesets") % (action,)

I am not sure why this is a part of patch. Can you explain?

REPOSITORY
  rHG Mercurial

REVISION DETAIL
  https://phab.mercurial-scm.org/D5940

To: navaneeth.suresh, #hg-reviewers
Cc: martinvonz, pulkit, mercurial-devel


More information about the Mercurial-devel mailing list