Add global options

This commit is contained in:
Shohei YOSHIDA 2026-03-15 15:14:40 +09:00
parent 96316552ea
commit d1180f126a
No known key found for this signature in database
GPG Key ID: C9A1BB11BB940CF2
1 changed files with 13 additions and 1 deletions

View File

@ -46,8 +46,20 @@ function _cask() {
local curcontext="$curcontext" local curcontext="$curcontext"
_arguments -C \ _arguments -C \
'(--proxy --http-proxy --https-proxy)--proxy[Set emacs proxy for HTTPS and HTTPS]:host:_hosts' \
'(--proxy --http-proxy)--http-proxy[Set emacs proxy for HTTP]:host:_hosts' \
'(--proxy --https-proxy)--https-proxy[Set emacs proxy for HTTPS]:host:_hosts' \
'(--proxy --http-proxy --https-proxy)--proxy[Set emacs proxy for HTTPS and HTTPS]:host:_hosts' \
'--no-proxy[Set Emacs no-proxy to HOST]:host:_hosts' \
'(- *)--version[Print Cask version and exit]' \
'(- *)'{-h,--help}'[Display usage or information for command]::command:->subcommand' \
'--debug[Turn on debug output]' \
'--path[Run command in this PATH instead of default-directory]:dir:_files -/' \
'(--verbose --silent)--verbose[Be verbose and show debug output]' \
'(--verbose --silent)--verbose[Be slient and do not show anything]' \
':subcommand:->subcommand' \ ':subcommand:->subcommand' \
'*:: :->subcmds' && ret=0 '*:: :->subcmds' \
&& ret=0
case $state in case $state in
(subcommand) (subcommand)