D971: uncommit: unify functions _uncommitdirstate and _unamenddirstate to one

durin42 (Augie Fackler) phabricator at mercurial-scm.org
Mon Nov 13 17:27:22 EST 2017


durin42 added subscribers: hooper, martinvonz, durin42.
durin42 accepted this revision as: durin42.
durin42 added a comment.


  (Marking accepted, but consider just moving this to `scmutil` or `rewriteutil` (I made that second one up, but it might be a sensible thing to have?) in parallel with the inevitable bikeshedding over on https://phab.mercurial-scm.org/D821.

INLINE COMMENTS

> uncommit.py:101
>  
> -def _uncommitdirstate(repo, oldctx, match):
> -    """Fix the dirstate after switching the working directory from
> -    oldctx to a copy of oldctx not containing changed files matched by
> -    match.
> +def _fixdirstate(repo, oldctx, newctx, status):
> +    """ fix the dirstate after switching the working directory from oldctx to

This looks like it should be a utility method in core. I think @martinvonz or @hooper ran into a case where this would have been helpful.

REPOSITORY
  rHG Mercurial

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

To: pulkit, #hg-reviewers, mbthomas, durin42
Cc: durin42, martinvonz, hooper, mercurial-devel


More information about the Mercurial-devel mailing list