File tree Expand file tree Collapse file tree 1 file changed +6
-3
lines changed Expand file tree Collapse file tree 1 file changed +6
-3
lines changed Original file line number Diff line number Diff line change @@ -401,7 +401,10 @@ def get_commands(platforms: Optional[List[str]] = None,
401
401
path = get_cache_dir () / pages_dir / platform
402
402
if not path .exists ():
403
403
continue
404
- commands += [f"{ file .stem } ({ language } )"
404
+ languagestring = ""
405
+ if language != 'en' :
406
+ languagestring = f" ({ language } )"
407
+ commands += [f"{ file .stem } { languagestring } "
405
408
for file in path .iterdir ()
406
409
if file .suffix == '.md' ]
407
410
return commands
@@ -654,10 +657,10 @@ def create_parser() -> ArgumentParser:
654
657
655
658
shtab .add_argument_to (parser , preamble = {
656
659
'bash' : r'''shtab_tldr_cmd_list(){{
657
- compgen -W "$("{py}" -m tldr --list | sed 's/[^[:alnum:]_]/ /g' )" -- "$1"
660
+ compgen -W "$("{py}" -m tldr --list)" -- "$1"
658
661
}}''' .format (py = sys .executable ),
659
662
'zsh' : r'''shtab_tldr_cmd_list(){{
660
- _describe 'command' "($("{py}" -m tldr --list | sed 's/[^[:alnum:]_]/ /g' ))"
663
+ _describe 'command' "($("{py}" -m tldr --list))"
661
664
}}''' .format (py = sys .executable )
662
665
})
663
666
You can’t perform that action at this time.
0 commit comments