Merge pull request #11468 from nandahkrishna/local-bottle-installs
formula_installer: improve support for local bottle installs
This commit is contained in:
commit
dfee6a9fd6
@ -404,7 +404,7 @@ class FormulaInstaller
|
||||
options = display_options(formula).join(" ")
|
||||
oh1 "Installing #{Formatter.identifier(formula.full_name)} #{options}".strip if show_header?
|
||||
|
||||
unless formula.tap&.private?
|
||||
if formula.tap&.installed? && !formula.tap&.private?
|
||||
action = "#{formula.full_name} #{options}".strip
|
||||
Utils::Analytics.report_event("install", action)
|
||||
|
||||
@ -1074,9 +1074,14 @@ class FormulaInstaller
|
||||
-I #{$LOAD_PATH.join(File::PATH_SEPARATOR)}
|
||||
--
|
||||
#{HOMEBREW_LIBRARY_PATH}/postinstall.rb
|
||||
#{formula.path}
|
||||
]
|
||||
|
||||
args << if formula.local_bottle_path.present?
|
||||
formula.prefix/".brew/#{formula.name}.rb"
|
||||
else
|
||||
formula.path
|
||||
end
|
||||
|
||||
Utils.safe_fork do
|
||||
if Sandbox.available?
|
||||
sandbox = Sandbox.new
|
||||
@ -1163,7 +1168,7 @@ class FormulaInstaller
|
||||
tab.source["versions"]["stable"] = formula.stable.version.to_s
|
||||
tab.source["versions"]["version_scheme"] = formula.version_scheme
|
||||
tab.source["path"] = formula.specified_path.to_s
|
||||
tab.source["tap_git_head"] = formula.tap&.git_head
|
||||
tab.source["tap_git_head"] = formula.tap&.installed? ? formula.tap&.git_head : nil
|
||||
tab.tap = formula.tap
|
||||
tab.write
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user