Timeline for With Homebrew, how to check if a software/package is installed?
Current License: CC BY-SA 4.0
7 events
when toggle format | what | by | license | comment | |
---|---|---|---|---|---|
Feb 27, 2021 at 3:52 | comment | added | airtonix | @JoshCorreia nah it's useless. you want to know it failed or not. this is why exit codes exist. | |
Feb 4, 2021 at 17:05 | comment | added | Josh Correia | @airtonix Just because it always has an exit code of 0 doesn't make it useless. As I mention in my post this method requires that you parse the response. | |
Feb 4, 2021 at 0:30 | comment | added | airtonix |
brew info always has a exit code 0. so it's useless. brew list [email protected] &>/dev/null || brew install [email protected]; works because it returns 1 when there's nothing found.
|
|
Oct 13, 2020 at 14:38 | comment | added | Raptor |
the disadvantage of brew info <formula> is that it loads very slowly, as it has to fetch the statistics of the formula from the Internet. If you use brew list <formula> | grep "No such keg" (or something similar), the result will be displayed much faster.
|
|
Jun 6, 2019 at 21:10 | review | Late answers | |||
Jun 7, 2019 at 3:54 | |||||
Jun 6, 2019 at 20:55 | review | First posts | |||
Jun 6, 2019 at 22:50 | |||||
Jun 6, 2019 at 20:53 | history | answered | Josh Correia | CC BY-SA 4.0 |