Mercurial > public > mercurial-scm > hg
comparison mercurial/commands.py @ 30065:ee21ed7fc7a2
bisect: extract the 'reset' logic into its own function
This is part of small clean up movement. The bisect module seem more appropriate
to host the bisect logic. The cleanup itself is motivated by some higher level
cleanup around vfs and locking.
author | Pierre-Yves David <pierre-yves.david@ens-lyon.org> |
---|---|
date | Wed, 24 Aug 2016 04:13:53 +0200 |
parents | b24804f72116 |
children | 5f93737d0ba8 |
comparison
equal
deleted
inserted
replaced
30064:b24804f72116 | 30065:ee21ed7fc7a2 |
---|---|
900 raise error.Abort(_('incompatible arguments')) | 900 raise error.Abort(_('incompatible arguments')) |
901 | 901 |
902 cmdutil.checkunfinished(repo) | 902 cmdutil.checkunfinished(repo) |
903 | 903 |
904 if reset: | 904 if reset: |
905 if repo.vfs.exists("bisect.state"): | 905 hbisect.resetstate(repo) |
906 repo.vfs.unlink("bisect.state") | |
907 return | 906 return |
908 | 907 |
909 state = hbisect.load_state(repo) | 908 state = hbisect.load_state(repo) |
910 | 909 |
911 if command: | 910 if command: |