Make new keep? superenv logic opt-in
Closes #50425. Signed-off-by: Misty De Meo <mistydemeo@github.com>
This commit is contained in:
parent
4fd5c5c159
commit
f8cdab7d8a
@ -201,6 +201,10 @@ class Cmd
|
|||||||
end
|
end
|
||||||
|
|
||||||
def keep?(path)
|
def keep?(path)
|
||||||
|
# The logic in this method will eventually become the default,
|
||||||
|
# but is currently opt-in.
|
||||||
|
return keep_orig?(path) unless ENV["HOMEBREW_EXPERIMENTAL_FILTER_FLAGS_ON_DEPS"]
|
||||||
|
|
||||||
# first two paths: reject references to Cellar or opt paths
|
# first two paths: reject references to Cellar or opt paths
|
||||||
# for unspecified dependencies
|
# for unspecified dependencies
|
||||||
if path.start_with?(cellar) || path.start_with?(opt)
|
if path.start_with?(cellar) || path.start_with?(opt)
|
||||||
@ -213,6 +217,11 @@ class Cmd
|
|||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
# The original less-smart version of keep_orig; will eventually be removed
|
||||||
|
def keep_orig?(path)
|
||||||
|
path.start_with?(prefix, cellar, tmpdir) || !path.start_with?("/opt", "/sw", "/usr/X11")
|
||||||
|
end
|
||||||
|
|
||||||
def cflags
|
def cflags
|
||||||
args = []
|
args = []
|
||||||
|
|
||||||
|
|||||||
@ -856,6 +856,7 @@ module Homebrew
|
|||||||
ENV["HOMEBREW_SANDBOX"] = "1"
|
ENV["HOMEBREW_SANDBOX"] = "1"
|
||||||
ENV["HOMEBREW_NO_EMOJI"] = "1"
|
ENV["HOMEBREW_NO_EMOJI"] = "1"
|
||||||
ENV["HOMEBREW_FAIL_LOG_LINES"] = "150"
|
ENV["HOMEBREW_FAIL_LOG_LINES"] = "150"
|
||||||
|
ENV["HOMEBREW_EXPERIMENTAL_FILTER_FLAGS_ON_DEPS"] = "1"
|
||||||
|
|
||||||
if ENV["TRAVIS"]
|
if ENV["TRAVIS"]
|
||||||
ARGV << "--verbose"
|
ARGV << "--verbose"
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user