Merge pull request #13677 from carlocab/python-libexec
ENV/super: add Python's `libexec/"bin"` directory when applicable
This commit is contained in:
commit
fb4c6d92bc
@ -130,8 +130,13 @@ module Superenv
|
||||
|
||||
sig { returns(T::Array[Pathname]) }
|
||||
def homebrew_extra_paths
|
||||
[]
|
||||
# Reverse sort by version so that we prefer the newest when there are multiple.
|
||||
deps.select { |d| d.name.match? Version.formula_optionally_versioned_regex(:python) }
|
||||
.sort_by(&:version)
|
||||
.reverse
|
||||
.map { |d| d.opt_libexec/"bin" }
|
||||
end
|
||||
alias generic_homebrew_extra_paths homebrew_extra_paths
|
||||
|
||||
sig { returns(T.nilable(PATH)) }
|
||||
def determine_path
|
||||
|
||||
@ -26,7 +26,7 @@ module Superenv
|
||||
end
|
||||
|
||||
def homebrew_extra_paths
|
||||
paths = []
|
||||
paths = generic_homebrew_extra_paths
|
||||
paths += %w[binutils make].map do |f|
|
||||
bin = Formulary.factory(f).opt_bin
|
||||
bin if bin.directory?
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user