Mercurial > public > mercurial-scm > hg-stable
comparison mercurial/cmdutil.py @ 25657:dcc56e10c23b
revert: change the direction of revert -i
After the discussion on the list about hg revert -i, it seems like we are
satisfied with what we called proposition 2. It shows the changes to revert in
the same direction as hg diff. This patch makes it the default option.
It changes all the + in - and vice versa in the tests for revert -i.
author | Laurent Charignon <lcharignon@fb.com> |
---|---|
date | Tue, 23 Jun 2015 14:28:15 -0700 |
parents | c2a4dfe2a336 |
children | 328739ea70c3 |
comparison
equal
deleted
inserted
replaced
25656:88d244f4edfd | 25657:dcc56e10c23b |
---|---|
3100 diffopts = patch.difffeatureopts(repo.ui, whitespace=True) | 3100 diffopts = patch.difffeatureopts(repo.ui, whitespace=True) |
3101 diffopts.nodates = True | 3101 diffopts.nodates = True |
3102 diffopts.git = True | 3102 diffopts.git = True |
3103 reversehunks = repo.ui.configbool('experimental', | 3103 reversehunks = repo.ui.configbool('experimental', |
3104 'revertalternateinteractivemode', | 3104 'revertalternateinteractivemode', |
3105 False) | 3105 True) |
3106 if reversehunks: | 3106 if reversehunks: |
3107 diff = patch.diff(repo, ctx.node(), None, m, opts=diffopts) | 3107 diff = patch.diff(repo, ctx.node(), None, m, opts=diffopts) |
3108 else: | 3108 else: |
3109 diff = patch.diff(repo, None, ctx.node(), m, opts=diffopts) | 3109 diff = patch.diff(repo, None, ctx.node(), m, opts=diffopts) |
3110 originalchunks = patch.parsepatch(diff) | 3110 originalchunks = patch.parsepatch(diff) |