Mercurial > public > mercurial-scm > hg
comparison mercurial/dispatch.py @ 12932:ab93029ab622 stable
alias: fall back to normal error handling for ambigious commands (fixes issue2475)
author | Steve Losh <steve@stevelosh.com> |
---|---|
date | Fri, 05 Nov 2010 15:54:32 -0400 |
parents | 4d657b524be8 |
children | a939f08fae9c |
comparison
equal
deleted
inserted
replaced
12930:9bb180abc4d0 | 12932:ab93029ab622 |
---|---|
451 addaliases(lui, cmdtable) | 451 addaliases(lui, cmdtable) |
452 | 452 |
453 cmd = args[0] | 453 cmd = args[0] |
454 try: | 454 try: |
455 aliases, entry = cmdutil.findcmd(cmd, cmdtable, lui.config("ui", "strict")) | 455 aliases, entry = cmdutil.findcmd(cmd, cmdtable, lui.config("ui", "strict")) |
456 except error.UnknownCommand: | 456 except (error.AmbiguousCommand, error.UnknownCommand): |
457 commands.norepo = norepo | 457 commands.norepo = norepo |
458 os.chdir(cwd) | 458 os.chdir(cwd) |
459 return | 459 return |
460 | 460 |
461 cmd = aliases[0] | 461 cmd = aliases[0] |