Skip to content
Snippets Groups Projects
Commit e8ef2125 authored by Mike McQuaid's avatar Mike McQuaid Committed by GitHub
Browse files

Merge pull request #2617 from MikeMcQuaid/interactive-home-access

Allow --interactive to access HOME
parents 25e9e658 7055abc4
No related branches found
No related tags found
No related merge requests found
......@@ -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
......
......@@ -664,6 +664,7 @@ class FormulaInstaller
sandbox = Sandbox.new
formula.logs.mkpath
sandbox.record_log(formula.logs/"build.sandbox.log")
sandbox.allow_write_path(ENV["HOME"]) if ARGV.interactive?
sandbox.allow_write_temp_and_cache
sandbox.allow_write_log(formula)
sandbox.allow_write_xcode
......
......@@ -5,10 +5,6 @@ class Sandbox
SANDBOX_EXEC = "/usr/bin/sandbox-exec".freeze
SANDBOXED_TAPS = %w[
homebrew/core
homebrew/dupes
homebrew/fuse
homebrew/devel-only
homebrew/tex
].freeze
def self.available?
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment