Mercurial > evolve
comparison hgext/evolve.py @ 1405:eaf82490af76
evolve: prevent using --rev and --any together
Before this patch it was possible to use evolve --rev --any and it meant
evolve --rev. This patch throws an error when using evolve --rev --any.
author | Laurent Charignon <lcharignon@fb.com> |
---|---|
date | Tue, 16 Jun 2015 16:58:38 -0700 |
parents | 848a04c078c7 |
children | 552687eb4856 |
comparison
equal
deleted
inserted
replaced
1404:848a04c078c7 | 1405:eaf82490af76 |
---|---|
1437 if tro is None: | 1437 if tro is None: |
1438 return _handlenotrouble(ui, repo, startnode, dryrunopt) | 1438 return _handlenotrouble(ui, repo, startnode, dryrunopt) |
1439 revs = set([tro]) | 1439 revs = set([tro]) |
1440 elif targetcat in repo['.'].troubles(): | 1440 elif targetcat in repo['.'].troubles(): |
1441 revs = set([repo['.'].rev()]) | 1441 revs = set([repo['.'].rev()]) |
1442 if revopt and anyopt: | |
1443 raise util.Abort('cannot specify both "--rev" and "--any"') | |
1442 if not revs: | 1444 if not revs: |
1443 msg = "no troubled changes in the specified revisions" | 1445 msg = "no troubled changes in the specified revisions" |
1444 raise util.Abort(msg) | 1446 raise util.Abort(msg) |
1445 | 1447 |
1446 # For the progress bar to show | 1448 # For the progress bar to show |