aboutsummaryrefslogtreecommitdiffstats
path: root/Library/Homebrew
diff options
context:
space:
mode:
authorMike McQuaid2016-01-27 10:29:58 +0000
committerMike McQuaid2016-01-27 12:49:25 +0000
commit7260b35c311cc78371f1e984ce78302b0a565d91 (patch)
tree495cfb82f041f4ae8a4600760ccee9fa800b71fb /Library/Homebrew
parente07b5a98e07121dbca02b2bba42b32caad7d7ff7 (diff)
downloadbrew-7260b35c311cc78371f1e984ce78302b0a565d91.tar.bz2
config: fail when HOMEBREW_BREW_FILE is unset.
Not sure why this is happening (beyond the Chef cookbook stupidly deciding to not call through `bin/brew`) but fail and print a scary looking error to hope to point people in the right direction. Closes Homebrew/homebrew#48261. Signed-off-by: Mike McQuaid <mike@mikemcquaid.com>
Diffstat (limited to 'Library/Homebrew')
-rw-r--r--Library/Homebrew/config.rb5
1 files changed, 3 insertions, 2 deletions
diff --git a/Library/Homebrew/config.rb b/Library/Homebrew/config.rb
index 692a43988..85c471328 100644
--- a/Library/Homebrew/config.rb
+++ b/Library/Homebrew/config.rb
@@ -26,8 +26,9 @@ undef cache
# Where brews installed via URL are cached
HOMEBREW_CACHE_FORMULA = HOMEBREW_CACHE+"Formula"
-unless defined? HOMEBREW_BREW_FILE
- HOMEBREW_BREW_FILE = ENV["HOMEBREW_BREW_FILE"] || which("brew").to_s
+HOMEBREW_BREW_FILE = ENV["HOMEBREW_BREW_FILE"]
+unless HOMEBREW_BREW_FILE
+ odie "HOMEBREW_BREW_FILE was not exported! Please call bin/brew directly!"
end
# Where we link under