diff -r 8cf3999b3d03 -r 81c563a254be mercurial/commands.py --- a/mercurial/commands.py Tue Jun 28 00:46:16 2005 -0800 +++ b/mercurial/commands.py Tue Jun 28 00:55:59 2005 -0800 @@ -851,13 +851,13 @@ help(u, cmd) sys.exit(-1) - if cmd not in norepo.split(): - repo = hg.repository(ui = u) - d = lambda: i[0](u, repo, *args, **cmdoptions) - else: - d = lambda: i[0](u, *args, **cmdoptions) + try: + if cmd not in norepo.split(): + repo = hg.repository(ui = u) + d = lambda: i[0](u, repo, *args, **cmdoptions) + else: + d = lambda: i[0](u, *args, **cmdoptions) - try: if options['profile']: import hotshot, hotshot.stats prof = hotshot.Profile("hg.prof") @@ -870,6 +870,8 @@ return r else: return d() + except hg.RepoError, inst: + u.warn("abort: ", inst, "!\n") except SignalInterrupt: u.warn("killed!\n") except KeyboardInterrupt: