buo / homebrew-cask-upgrade

A command line tool for upgrading every outdated app installed by Homebrew Cask
MIT License
2.4k stars 90 forks source link

Adding support for multiple casks as arguments and wildcard search #127

Closed ondrejfuhrer closed 5 years ago

ondrejfuhrer commented 5 years ago

Resolves #126

This is adding support for multiple arguments in the cu command as folows:

>> brew cu -acf flash-npapi flash-ppapi                                                                                                                                                                                                        1 ↵  10018  10:47:51
==> Options
Include auto-update (-a): true
Include latest (-f): true
==> Updating Homebrew
Already up-to-date.
==> Finding outdated apps
     Cask         Current     Latest      A/U    Result
1/2  flash-npapi  31.0.0.122  31.0.0.148   Y   [ FORCED ]
2/2  flash-ppapi  31.0.0.122  31.0.0.148   Y   [ FORCED ]
==> Found outdated apps
     Cask         Current     Latest      A/U    Result
1/2  flash-npapi  31.0.0.122  31.0.0.148   Y   [ FORCED ]
2/2  flash-ppapi  31.0.0.122  31.0.0.148   Y   [ FORCED ]

Do you want to upgrade 2 apps [y/N]?

Also added support for prefix search, i.e. :

>> brew cu -acf flash-\*                                                                                                                                                                                                                           10019  10:52:58
==> Options
Include auto-update (-a): true
Include latest (-f): true
==> Updating Homebrew
Already up-to-date.
==> Finding outdated apps
     Cask         Current     Latest      A/U    Result
1/2  flash-npapi  31.0.0.122  31.0.0.148   Y   [ FORCED ]
2/2  flash-ppapi  31.0.0.122  31.0.0.148   Y   [ FORCED ]
==> Found outdated apps
     Cask         Current     Latest      A/U    Result
1/2  flash-npapi  31.0.0.122  31.0.0.148   Y   [ FORCED ]
2/2  flash-ppapi  31.0.0.122  31.0.0.148   Y   [ FORCED ]

Do you want to upgrade 2 apps [y/N]?

Enjoy! 🙂

muescha commented 5 years ago

i miss an updated README and the --help

muescha commented 5 years ago

why you added a backslash in >> brew cu -acf flash-\* ?

because for me it works with an single *

brew cu libre*
==> Options                                                                                                                                                             
Include auto-update (-a): false                                                                                                                                         
Include latest (-f): false                                                                                                                                              
==> Updating Homebrew                                                                                                                                                   
Already up-to-date.                                                                                                                                                     
==> Finding outdated apps                                                                                                                                               
     Cask                       Current  Latest  A/U    Result                                                                                                          
1/2  libreoffice                6.1.4    6.2.0        [OUTDATED]                                                                                                        
2/2  libreoffice-language-pack  6.1.4    6.2.0        [OUTDATED]                                                                                                        
==> Found outdated apps                                                                                                                                                 
     Cask                       Current  Latest  A/U    Result                                                                                                          
1/2  libreoffice                6.1.4    6.2.0        [OUTDATED]                                                                                                        
2/2  libreoffice-language-pack  6.1.4    6.2.0        [OUTDATED]                                                                                                        

Do you want to upgrade 2 apps [y/N]? y    
ondrejfuhrer commented 5 years ago

Hey @muescha , could be, but didn't work for me for whatever reason, might be a different terminal app or anything else. I put there what worked for me 🙂

muescha commented 5 years ago

ok