aboutsummaryrefslogtreecommitdiffstats
path: root/Library/Homebrew/utils.rb
diff options
context:
space:
mode:
authorJack Nagel2012-05-13 19:00:10 -0500
committerJack Nagel2012-05-13 19:28:03 -0500
commit2fb94e4d9b90c22f8b6c2e3757ae90dd6038a790 (patch)
tree8612d47b7020b297290873a6403fe13d291241af /Library/Homebrew/utils.rb
parentbfb295616a5eec6c2331ea7ec41c61bde72f965c (diff)
downloadhomebrew-2fb94e4d9b90c22f8b6c2e3757ae90dd6038a790.tar.bz2
Use 'which' helper method more
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
Diffstat (limited to 'Library/Homebrew/utils.rb')
-rw-r--r--Library/Homebrew/utils.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/Library/Homebrew/utils.rb b/Library/Homebrew/utils.rb
index f5530c29f..de797f2d6 100644
--- a/Library/Homebrew/utils.rb
+++ b/Library/Homebrew/utils.rb
@@ -482,8 +482,8 @@ module MacOS extend self
return false unless MACOS
%w[port fink].each do |ponk|
- path = `/usr/bin/which #{ponk} 2>/dev/null`
- return ponk unless path.empty?
+ path = which(ponk)
+ return ponk unless path.nil?
end
# we do the above check because macports can be relocated and fink may be