This is an archive of the discontinued Mercurial Phabricator instance.

resolve: support confirm config option with --unmark flag
ClosedPublic

Authored by khanchi97 on Aug 4 2018, 3:31 AM.

Details

Summary

Now, commands.resolve.confirm also respect --unmark option; and
confirm to unresolve all resolved files.
It will confirm only when no files pats are passed (same as --mark),
because when no pats are passed the default is to mark resolved files
as unresolved.
And if user has passed file pats then I think there is no need to confirm
for that.

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

khanchi97 created this revision.Aug 4 2018, 3:31 AM
pulkit added a subscriber: pulkit.Aug 4 2018, 1:11 PM
pulkit added inline comments.
mercurial/commands.py
4555

This should be 'mark all resolved files as unresolved'.

khanchi97 added inline comments.Aug 4 2018, 2:18 PM
mercurial/commands.py
4555

Oops, sorry.

khanchi97 updated this revision to Diff 9905.Aug 4 2018, 2:19 PM
pulkit accepted this revision.Aug 5 2018, 10:20 PM
pulkit added inline comments.
mercurial/commands.py
4555

You should not be sorry!

Please add about this config option in the releasenotes page for 4.8 at https://www.mercurial-scm.org/wiki/Release4.8.

mercurial/commands.py
4537

This one should be moved after conditional in line 4544. Also we can now better organize the three if 'confirm' conditionals now. Can you please follow-up?

This revision was automatically updated to reflect the committed changes.