[Updated] D11508: histedit: remove redundant checks for unfinished histedit state
martinvonz (Martin von Zweigbergk)
phabricator at mercurial-scm.org
Wed Sep 29 11:13:30 UTC 2021
Closed by commit rHG6256c7525222: histedit: remove redundant checks for unfinished histedit state (authored by martinvonz).
This revision was automatically updated to reflect the committed changes.
REPOSITORY
rHG Mercurial
CHANGES SINCE LAST UPDATE
https://phab.mercurial-scm.org/D11508?vs=30431&id=30440
CHANGES SINCE LAST ACTION
https://phab.mercurial-scm.org/D11508/new/
REVISION DETAIL
https://phab.mercurial-scm.org/D11508
AFFECTED FILES
hgext/histedit.py
CHANGE DETAILS
diff --git a/hgext/histedit.py b/hgext/histedit.py
--- a/hgext/histedit.py
+++ b/hgext/histedit.py
@@ -1697,13 +1697,6 @@
cmdutil.checkunfinished(repo)
cmdutil.bailifchanged(repo)
- if os.path.exists(os.path.join(repo.path, b'histedit-state')):
- raise error.Abort(
- _(
- b'history edit already in progress, try '
- b'--continue or --abort'
- )
- )
revs.extend(freeargs)
if not revs:
defaultrev = destutil.desthistedit(ui, repo)
@@ -1928,7 +1921,7 @@
return f.read()
-def _validateargs(ui, repo, state, freeargs, opts, goal, rules, revs):
+def _validateargs(ui, repo, freeargs, opts, goal, rules, revs):
# TODO only abort if we try to histedit mq patches, not just
# blanket if mq patches are applied somewhere
mq = getattr(repo, 'mq', None)
@@ -1954,13 +1947,6 @@
_(b'only --commands argument allowed with --edit-plan')
)
else:
- if state.inprogress():
- raise error.Abort(
- _(
- b'history edit already in progress, try '
- b'--continue or --abort'
- )
- )
if outg:
if revs:
raise error.Abort(_(b'no revisions allowed with --outgoing'))
@@ -1990,7 +1976,7 @@
rules = opts.get(b'commands', b'')
state.keep = opts.get(b'keep', False)
- _validateargs(ui, repo, state, freeargs, opts, goal, rules, revs)
+ _validateargs(ui, repo, freeargs, opts, goal, rules, revs)
hastags = False
if revs:
To: martinvonz, durin42, #hg-reviewers, Alphare
Cc: mercurial-patches
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mercurial-scm.org/pipermail/mercurial-patches/attachments/20210929/df7fcc01/attachment-0002.html>
More information about the Mercurial-patches
mailing list