Merge pull request #17313 from Homebrew/utils_gems_homebrew_cache
utils/gems: handle undefined `HOMEBREW_CACHE`.
This commit is contained in:
commit
36baa15a7c
@ -244,7 +244,12 @@ module Homebrew
|
|||||||
groups |= (user_gem_groups & valid_gem_groups)
|
groups |= (user_gem_groups & valid_gem_groups)
|
||||||
groups.sort!
|
groups.sort!
|
||||||
|
|
||||||
ENV["BUNDLE_CACHE_PATH"] = (HOMEBREW_CACHE/"bundler_cache").to_s
|
homebrew_cache = if defined?(HOMEBREW_CACHE)
|
||||||
|
HOMEBREW_CACHE.to_s
|
||||||
|
else
|
||||||
|
ENV.fetch("HOMEBREW_CACHE")
|
||||||
|
end
|
||||||
|
ENV["BUNDLE_CACHE_PATH"] = "#{homebrew_cache}/bundler_cache"
|
||||||
ENV["BUNDLE_GEMFILE"] = gemfile
|
ENV["BUNDLE_GEMFILE"] = gemfile
|
||||||
ENV["BUNDLE_WITH"] = groups.join(" ")
|
ENV["BUNDLE_WITH"] = groups.join(" ")
|
||||||
ENV["BUNDLE_FROZEN"] = "true"
|
ENV["BUNDLE_FROZEN"] = "true"
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user