mirror of
https://github.com/xonsh/xonsh.git
synced 2025-03-06 09:20:57 +01:00
aliases
This commit is contained in:
parent
73beffb87a
commit
167052c0b1
2 changed files with 5 additions and 1 deletions
|
@ -167,7 +167,7 @@ def parser():
|
|||
'Possible options: readline, prompt_toolkit, random. '
|
||||
'Warning! If set this overrides $SHELL_TYPE variable.',
|
||||
dest='shell_type',
|
||||
choices=('readline', 'prompt_toolkit', 'best', 'random'),
|
||||
choices=tuple(Shell.shell_type_aliases.keys()),
|
||||
default=None)
|
||||
p.add_argument('--timings',
|
||||
help='Prints timing information before the prompt is shown. '
|
||||
|
|
|
@ -95,14 +95,18 @@ class Shell(object):
|
|||
|
||||
shell_type_aliases = {
|
||||
'b': 'best',
|
||||
'best': 'best',
|
||||
'ptk': 'prompt_toolkit',
|
||||
'ptk1': 'prompt_toolkit1',
|
||||
'ptk2': 'prompt_toolkit2',
|
||||
'prompt-toolkit': 'prompt_toolkit',
|
||||
'prompt_toolkit': 'prompt_toolkit',
|
||||
'prompt-toolkit1': 'prompt_toolkit1',
|
||||
'prompt-toolkit2': 'prompt_toolkit2',
|
||||
'rand': 'random',
|
||||
'random': 'random',
|
||||
'rl': 'readline',
|
||||
'readline': 'readline',
|
||||
}
|
||||
|
||||
def __init__(self, execer, ctx=None, shell_type=None, **kwargs):
|
||||
|
|
Loading…
Add table
Reference in a new issue