mirror of
git://git.code.sf.net/p/zsh/code
synced 2025-09-23 04:51:12 +02:00
Python modules can behave like commands in their own right. This allows modules to define _python_module-* functions that are used to complete module arguments. Also gets the ball rolling by defining completions for venv, http.server, and json.tool.
13 lines
620 B
Bash
13 lines
620 B
Bash
#autoload
|
|
|
|
_arguments -S \
|
|
'(-h --help)'{-h,--help}'[show a help message and exit]' \
|
|
'--sort-keys[sort the output of dictionaries alphabetically by key]' \
|
|
'--no-ensure-ascii[disable escaping of non-ASCII characters]' \
|
|
'--json-lines[parse input using the JSON Lines format]' \
|
|
'--indent=[separate items with newlines and use this number of spaces for indentation]:spaces:' \
|
|
'--tab[separate items with newlines and use tabs for indentation]' \
|
|
'--no-indent[separate items with spaces rather than newlines]' \
|
|
'--compact[suppress all whitespace separation]' \
|
|
'1:infile:_files' \
|
|
'2:outfile:_files'
|