diff --git a/hgext/split.py b/hgext/split.py --- a/hgext/split.py +++ b/hgext/split.py @@ -108,6 +108,7 @@ if len(ctx.parents()) > 1: raise error.Abort(_('cannot split a merge changeset')) + cmdutil.checkunfinished(repo) cmdutil.bailifchanged(repo) # Deactivate bookmark temporarily so it won't get moved unintentionally diff --git a/tests/test-split.t b/tests/test-split.t --- a/tests/test-split.t +++ b/tests/test-split.t @@ -91,6 +91,15 @@ $ hg forget dirty $ rm dirty +Cannot split while there's an unfinished operation + + $ touch .hg/graftstate + $ hg split . + abort: graft in progress + (use 'hg graft --continue' or 'hg graft --stop' to stop) + [255] + $ rm .hg/graftstate + Make a clean directory for future tests to build off of $ cp -R . ../clean