From d7097b5598bc120db273008190f278e01d8a3586 Mon Sep 17 00:00:00 2001 From: Akylzhan Sauranbay Date: Tue, 8 Sep 2020 20:10:21 +0600 Subject: [PATCH 1/2] Fix the usage of outdated brew cask list --- completions/zsh/_brew_cask | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/completions/zsh/_brew_cask b/completions/zsh/_brew_cask index 78bcbfb8f6..5b26a3325a 100644 --- a/completions/zsh/_brew_cask +++ b/completions/zsh/_brew_cask @@ -32,7 +32,7 @@ __brew_all_casks() { __brew_installed_casks() { local -a list local expl - list=( $(__brew_cask list|sed 's/(!)//') ) + list=( $(brew list --cask) ) _wanted list expl 'installed casks' compadd -a list } @@ -136,10 +136,6 @@ _brew_cask_list() { '*::token:__brew_installed_casks' } -_brew_cask_ls() { - _brew_cask_list -} - _brew_cask_outdated() { _arguments : \ '--greedy:also list Casks with auto_updates or version \:latest' \ From 8fd565403ed06efcb83e3c9e08fb7de1083f3da8 Mon Sep 17 00:00:00 2001 From: Akylzhan Sauranbay Date: Thu, 10 Sep 2020 00:33:11 +0600 Subject: [PATCH 2/2] Remove unused zsh completions --- completions/zsh/_brew_cask | 8 -------- 1 file changed, 8 deletions(-) diff --git a/completions/zsh/_brew_cask b/completions/zsh/_brew_cask index 5b26a3325a..44f5cc869b 100644 --- a/completions/zsh/_brew_cask +++ b/completions/zsh/_brew_cask @@ -12,10 +12,6 @@ zstyle -T ':completion:*:*:*:brew-cask:*' tag-order && \ zstyle ':completion:*:*:*:brew-cask:*' tag-order 'commands' -__brew_cask() { - [ -d "$(brew --repo homebrew/cask)" ] && brew cask $@ -} - __brew_all_casks() { local -a list local expl @@ -91,10 +87,6 @@ _brew_cask_cat() { __brew_all_casks } -_brew_cask_cat() { - __brew_all_casks -} - _brew_cask_create() { _arguments '*::token:' }