diff --git a/mercurial/shelve.py b/mercurial/shelve.py --- a/mercurial/shelve.py +++ b/mercurial/shelve.py @@ -1008,6 +1008,8 @@ if interactive and opts.get('keep'): raise error.Abort(_('--keep on --interactive is not yet supported')) + if interactive and unresolved: + raise error.Abort(_('cannot use both interactive and unresolved')) if abortf or continuef: if abortf and continuef: raise error.Abort(_('cannot use both abort and continue')) diff --git a/tests/test-shelve-unresolved.t b/tests/test-shelve-unresolved.t --- a/tests/test-shelve-unresolved.t +++ b/tests/test-shelve-unresolved.t @@ -220,6 +220,11 @@ A C +-- abort on using both --interactive and --unresolved + $ hg unshelve --unresolved --interactive + abort: cannot use both interactive and unresolved + [255] + -- flag --unshelve is not passed. but, the last shelve is unresolved $ hg unshelve unshelving change 'default'