Browse code

update brew plugin from homebrew contributions

Daniel Schauenberg authored on 09/08/2010 at 13:45:40
Showing 1 changed files
... ...
@@ -1,6 +1,6 @@
1 1
 #compdef brew
2 2
 
3
-# copied from _fink
3
+# imported from the latest homebrew contributions
4 4
 
5 5
 _brew_all_formulae() {
6 6
   formulae=(`brew search`)
... ...
@@ -12,19 +12,25 @@ _brew_installed_formulae() {
12 12
 
13 13
 local -a _1st_arguments
14 14
 _1st_arguments=(
15
+  'cat:display formula file for a formula'
16
+  'cleanup:uninstall unused and old versions of packages'
17
+  'create:create a new formula'
18
+  'deps:list dependencies and dependants of a formula'
19
+  'doctor:audits your installation for common issues'
20
+  'edit:edit a formula'
21
+  'home:visit the homepage of a formula or the brew project'
22
+  'info:information about a formula'
15 23
   'install:install a formula'
24
+  'link:link a formula'
25
+  'list:list files in a formula or not-installed formulae'
26
+  'log:git commit log for a formula'
27
+  'outdated:list formulas for which a newer version is available'
28
+  'prune:remove dead links'
16 29
   'remove:remove a formula'
17 30
   'search:search for a formula (/regex/ or string)'
18
-  'list:list files in a formula or not-installed formulae'
19
-  'link:link a formula'
20 31
   'unlink:unlink a formula'
21
-  'home:visit the homepage of a formula or the brew project'
22
-  'info:information about a formula'
23
-  'prune:remove dead links'
24 32
   'update:freshen up links'
25
-  'log:git commit log for a formula'
26
-  'create:create a new formula'
27
-  'edit:edit a formula'
33
+  'uses:show formulas which depend on a formula'
28 34
 )
29 35
 
30 36
 local expl
... ...
@@ -47,12 +53,12 @@ case "$words[1]" in
47 47
     _arguments \
48 48
       '(--unbrewed)--unbrewed[files in brew --prefix not controlled by brew]' \
49 49
       '1: :->forms' &&  return 0
50
-      
50
+
51 51
       if [[ "$state" == forms ]]; then
52 52
         _brew_installed_formulae
53 53
         _requested installed_formulae expl 'installed formulae' compadd -a installed_formulae
54 54
       fi ;;
55
-  install|home|log|info)
55
+  install|home|log|info|uses|cat|deps)
56 56
     _brew_all_formulae
57 57
     _wanted formulae expl 'all formulae' compadd -a formulae ;;
58 58
   remove|edit|xo)