mirror of
https://github.com/Homebrew/brew.git
synced 2025-07-14 16:09:03 +08:00
Only directories are candidates for superenv bin
This commit is contained in:
parent
722a5af4eb
commit
6cdc76452b
@ -4,7 +4,7 @@ require 'extend/ENV/std'
|
|||||||
require 'extend/ENV/super'
|
require 'extend/ENV/super'
|
||||||
|
|
||||||
def superenv?
|
def superenv?
|
||||||
Superenv.bin && Superenv.bin.directory? && ARGV.env != "std"
|
Superenv.bin && ARGV.env != "std"
|
||||||
end
|
end
|
||||||
|
|
||||||
module EnvActivation
|
module EnvActivation
|
||||||
|
@ -40,7 +40,7 @@ module Superenv
|
|||||||
end
|
end
|
||||||
|
|
||||||
def self.bin
|
def self.bin
|
||||||
@bin ||= (HOMEBREW_REPOSITORY/"Library/ENV").children.reject{|d| d.basename.to_s > MacOS::Xcode.version }.max
|
@bin ||= (HOMEBREW_REPOSITORY/"Library/ENV").subdirs.reject { |d| d.basename.to_s > MacOS::Xcode.version }.max
|
||||||
end
|
end
|
||||||
|
|
||||||
def reset
|
def reset
|
||||||
|
Loading…
x
Reference in New Issue
Block a user