diff --git a/hgext/mq.py b/hgext/mq.py --- a/hgext/mq.py +++ b/hgext/mq.py @@ -2546,9 +2546,6 @@ def fold(ui, repo, *files, **opts): q.checklocalchanges(repo) message = cmdutil.logmessage(ui, opts) - if opts.get('edit'): - if message: - raise util.Abort(_('option "-e" incompatible with "-m" or "-l"')) parent = q.lookup('qtip') patches = [] diff --git a/tests/test-mq-qfold.t b/tests/test-mq-qfold.t --- a/tests/test-mq-qfold.t +++ b/tests/test-mq-qfold.t @@ -174,10 +174,11 @@ Test saving last-message.txt: $ hg tip --template "{files}\n" aa -(test that editor is not invoked before transaction starting) +(test that editor is not invoked before transaction starting, +and that combination of '--edit' and '--message' doesn't abort execution) $ rm -f .hg/last-message.txt - $ HGEDITOR="sh $TESTTMP/editor.sh" hg qfold -e p3 + $ HGEDITOR="sh $TESTTMP/editor.sh" hg qfold -e -m MESSAGE p3 refresh interrupted while patch was popped! (revert --all, qpush to recover) abort: emulating unexpected abort [255]