Merge pull request #8650 from Akylzhan/patch-1
Replace the usage of outdated brew cask list in zsh completion
This commit is contained in:
commit
36f47393c7
@ -12,10 +12,6 @@
|
|||||||
zstyle -T ':completion:*:*:*:brew-cask:*' tag-order && \
|
zstyle -T ':completion:*:*:*:brew-cask:*' tag-order && \
|
||||||
zstyle ':completion:*:*:*:brew-cask:*' tag-order 'commands'
|
zstyle ':completion:*:*:*:brew-cask:*' tag-order 'commands'
|
||||||
|
|
||||||
__brew_cask() {
|
|
||||||
[ -d "$(brew --repo homebrew/cask)" ] && brew cask $@
|
|
||||||
}
|
|
||||||
|
|
||||||
__brew_all_casks() {
|
__brew_all_casks() {
|
||||||
local -a list
|
local -a list
|
||||||
local expl
|
local expl
|
||||||
@ -32,7 +28,7 @@ __brew_all_casks() {
|
|||||||
__brew_installed_casks() {
|
__brew_installed_casks() {
|
||||||
local -a list
|
local -a list
|
||||||
local expl
|
local expl
|
||||||
list=( $(__brew_cask list|sed 's/(!)//') )
|
list=( $(brew list --cask) )
|
||||||
_wanted list expl 'installed casks' compadd -a list
|
_wanted list expl 'installed casks' compadd -a list
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -91,10 +87,6 @@ _brew_cask_cat() {
|
|||||||
__brew_all_casks
|
__brew_all_casks
|
||||||
}
|
}
|
||||||
|
|
||||||
_brew_cask_cat() {
|
|
||||||
__brew_all_casks
|
|
||||||
}
|
|
||||||
|
|
||||||
_brew_cask_create() {
|
_brew_cask_create() {
|
||||||
_arguments '*::token:'
|
_arguments '*::token:'
|
||||||
}
|
}
|
||||||
@ -136,10 +128,6 @@ _brew_cask_list() {
|
|||||||
'*::token:__brew_installed_casks'
|
'*::token:__brew_installed_casks'
|
||||||
}
|
}
|
||||||
|
|
||||||
_brew_cask_ls() {
|
|
||||||
_brew_cask_list
|
|
||||||
}
|
|
||||||
|
|
||||||
_brew_cask_outdated() {
|
_brew_cask_outdated() {
|
||||||
_arguments : \
|
_arguments : \
|
||||||
'--greedy:also list Casks with auto_updates or version \:latest' \
|
'--greedy:also list Casks with auto_updates or version \:latest' \
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user