mirror of
https://github.com/alacritty/alacritty.git
synced 2024-11-25 14:05:41 -05:00
d86eff6f14
Declaring curcontext etc local is superfluous as _arguments states are not used. It is also superfluous to include an outer function definition syntax in zsh autoloadable functions. Zsh convention is not to capitalize descriptions. It is also better to use the imperative mood verb form for descriptions as this allows them to start with the shortest form of the verb - e.g. "reduce" instead of "reduces" and results in better grammar in the absence of a sentence subject. I'd recommend this in the --help output too. Using _guard for the position and dimensions was unnecessary given that the values are not mixed with other matches.
22 lines
1.2 KiB
Text
22 lines
1.2 KiB
Text
#compdef alacritty
|
|
|
|
local ign
|
|
|
|
(( $#words > 2 )) && ign='!'
|
|
_arguments \
|
|
"$ign(-)"{-h,--help}"[print help information]" \
|
|
"(--no-live-config-reload)--live-config-reload[enable automatic config reloading]" \
|
|
"(--live-config-reload)--no-live-config-reload[disable automatic config reloading]" \
|
|
"(--persistent-logging)--persistent-logging[keep the log file after quitting Alacritty]" \
|
|
"--print-events[print all events to stdout]" \
|
|
'(-v)'{-q,-qq}"[reduce the level of verbosity (min is -qq)]" \
|
|
"--ref-test[generate ref test]" \
|
|
'(-q)'{-v,-vv,-vvv}"[increase the level of verbosity (max is -vvv)]" \
|
|
"$ign(-)"{-V,--version}"[print version information]" \
|
|
"--class=[define the window class]:class" \
|
|
"(-e --command)"{-e,--command}"[execute command (must be last arg)]:program: _command_names -e:*::program arguments: _normal" \
|
|
"--config-file=[specify an alternative config file]:file:_files" \
|
|
"(-d --dimensions)"{-d,--dimensions}"[specify window dimensions]:columns: :lines" \
|
|
"--position[specify window position]:x position: :y position" \
|
|
"(-t --title)"{-t+,--title=}"[define the window title]:title" \
|
|
"--working-directory=[start shell in specified directory]:directory:_directories"
|