show sub options
This commit is contained in:
parent
8060586d8b
commit
412d18f218
1 changed files with 8 additions and 2 deletions
|
@ -79,12 +79,18 @@ def fish_completion():
|
||||||
'__borgmatic_check_version &',
|
'__borgmatic_check_version &',
|
||||||
) + tuple(
|
) + tuple(
|
||||||
'''complete -c borgmatic -a '%s' -d %s -f'''
|
'''complete -c borgmatic -a '%s' -d %s -f'''
|
||||||
% (action, shlex.quote(subparser.description))
|
% (actionStr, shlex.quote(subparser.description))
|
||||||
for action, subparser in subparsers.choices.items()
|
for actionStr, subparser in subparsers.choices.items()
|
||||||
) + tuple(
|
) + tuple(
|
||||||
'''complete -c borgmatic -a '%s' -d %s -f'''
|
'''complete -c borgmatic -a '%s' -d %s -f'''
|
||||||
% (option, shlex.quote(action.help))
|
% (option, shlex.quote(action.help))
|
||||||
for action in top_level_parser._actions
|
for action in top_level_parser._actions
|
||||||
for option in action.option_strings
|
for option in action.option_strings
|
||||||
|
) + tuple(
|
||||||
|
'''complete -c borgmatic -a '%s' -d %s -f -n "__fish_seen_subcommand_from %s"'''
|
||||||
|
% (option, shlex.quote(action.help), actionStr)
|
||||||
|
for actionStr, subparser in subparsers.choices.items()
|
||||||
|
for action in subparser._actions
|
||||||
|
for option in action.option_strings
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
|
|
Loading…
Reference in a new issue