diff -r 844d83da2da9 -r a5576908b589 mercurial/commands.py --- a/mercurial/commands.py Sun Feb 07 00:43:24 2010 +0100 +++ b/mercurial/commands.py Sun Feb 07 00:51:59 2010 +0100 @@ -2136,16 +2136,19 @@ branch = repo.changectx(None).branch() bheads = repo.branchheads(branch) if len(bheads) > 2: - raise util.Abort(_("branch '%s' has %d heads - " - "please merge with an explicit rev") % - (branch, len(bheads))) + ui.warn(_("abort: branch '%s' has %d heads - " + "please merge with an explicit rev\n") + % (branch, len(bheads))) + ui.status(_("(run 'hg heads .' to see heads)\n")) + return False parent = repo.dirstate.parents()[0] if len(bheads) == 1: if len(repo.heads()) > 1: - raise util.Abort(_("branch '%s' has one head - " - "please merge with an explicit rev") % - branch) + ui.warn(_("abort: branch '%s' has one head - " + "please merge with an explicit rev\n" % branch)) + ui.status(_("(run 'hg heads' to see all heads)\n")) + return False msg = _('there is nothing to merge') if parent != repo.lookup(repo[None].branch()): msg = _('%s - use "hg update" instead') % msg