Merge pull request #19716 from Homebrew/move_homebrew_bootsnap_gem_path

utils/ruby: set HOMEBREW_BOOTSNAP_GEM_PATH after Ruby install.
This commit is contained in:
Mike McQuaid 2025-04-07 16:10:50 +00:00 committed by GitHub
commit 58df019fcc
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -127,15 +127,15 @@ If there's no Homebrew Portable Ruby available for your processor:
if [[ -x "${vendor_ruby_path}" ]]
then
HOMEBREW_RUBY_PATH="${vendor_ruby_path}"
HOMEBREW_BOOTSNAP_GEM_PATH="$(
shopt -s nullglob
echo "${vendor_ruby_root}"/lib/ruby/gems/*/gems/bootsnap-*/lib/bootsnap 2>/dev/null
)"
TERMINFO_DIRS="${vendor_ruby_terminfo}"
if [[ "${vendor_ruby_current_version}" != "${HOMEBREW_PORTABLE_RUBY_VERSION}" ]]
then
brew vendor-install ruby || odie "${upgrade_fail}"
fi
HOMEBREW_BOOTSNAP_GEM_PATH="$(
shopt -s nullglob
echo "${vendor_ruby_root}"/lib/ruby/gems/*/gems/bootsnap-*/lib/bootsnap 2>/dev/null
)"
else
if system_ruby_supported
then