diff options
| author | Mike McQuaid | 2017-05-09 20:00:11 +0100 |
|---|---|---|
| committer | Mike McQuaid | 2017-05-09 20:00:11 +0100 |
| commit | 7055abc43670b48b874a0088990b068f2fa34c9f (patch) | |
| tree | 4401e8bbab0a5ee793625f857662401df134b31a /Library/Homebrew/formula.rb | |
| parent | f1d4c4be78905be0d5fd83922ff1262ed92ba4e8 (diff) | |
| download | brew-7055abc43670b48b874a0088990b068f2fa34c9f.tar.bz2 | |
Allow --interactive to access HOME
This may result in a slightly varied build but it’s generally just far
less annoying to be able to access all your e.g. shell configuration.
Diffstat (limited to 'Library/Homebrew/formula.rb')
| -rw-r--r-- | Library/Homebrew/formula.rb | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/Library/Homebrew/formula.rb b/Library/Homebrew/formula.rb index 17a34dd13..1b3b718da 100644 --- a/Library/Homebrew/formula.rb +++ b/Library/Homebrew/formula.rb @@ -1943,8 +1943,10 @@ class Formula old_curl_home = ENV["CURL_HOME"] old_path = ENV["HOMEBREW_PATH"] - ENV["HOME"] = env_home - ENV["CURL_HOME"] = old_curl_home || old_home + unless ARGV.interactive? + ENV["HOME"] = env_home + ENV["CURL_HOME"] = old_curl_home || old_home + end ENV["HOMEBREW_PATH"] = nil setup_home env_home @@ -1955,8 +1957,10 @@ class Formula yield staging ensure @buildpath = nil - ENV["HOME"] = old_home - ENV["CURL_HOME"] = old_curl_home + unless ARGV.interactive? + ENV["HOME"] = old_home + ENV["CURL_HOME"] = old_curl_home + end ENV["HOMEBREW_PATH"] = old_path end end |
