completions: handle installed/outdated formulae and casks

This commit is contained in:
nandahkrishna 2021-03-16 10:52:18 +05:30
parent fdf7c3136b
commit d73b335c77
No known key found for this signature in database
GPG Key ID: 067E5FCD58ADF3AA

View File

@ -223,7 +223,7 @@ module Homebrew
next unless ZSH_NAMED_ARGS_COMPLETION_FUNCTION_MAPPING.key? type
args_options << "- #{type}"
opt = "--#{type}"
opt = "--#{type.to_s.gsub(/(installed|outdated)_/, "")}"
if options.key?(opt)
desc = options[opt]