aboutsummaryrefslogtreecommitdiffstats
path: root/Library/Homebrew/cmd/outdated.rb
diff options
context:
space:
mode:
authorJack Nagel2012-01-27 03:19:53 -0600
committerJack Nagel2012-01-27 03:40:24 -0600
commit8944cc6b663318f94d20d92cd3b2716457ec37bb (patch)
tree7415b27f1275e86befddd1b5745d2b8e451a4b80 /Library/Homebrew/cmd/outdated.rb
parentd10f2afbacbdd0cbe58c0be7c6384e98c576059b (diff)
downloadbrew-8944cc6b663318f94d20d92cd3b2716457ec37bb.tar.bz2
versions: fix up error handling
Now we handle some things more explicitly and in the process get rid of the blanket rescue on the mktemp block, which is something of an antipattern. By unloading the class *after* determining the version, we avoid the case where the class had previously been unloaded but Formula.factory failed, and trying to unload the nonexistent class results in a NameError. Doing it this way, we avoid having to rescue NameError and thereby avoid hiding other cases where it may occur. We also rescue TypeError which gets us past a few more bad formula in the history in some instances. Signed-off-by: Jack Nagel <jacknagel@gmail.com>
Diffstat (limited to 'Library/Homebrew/cmd/outdated.rb')
0 files changed, 0 insertions, 0 deletions