Skip to content

Commit

Permalink
Merge pull request #2406 from rbenv/jruby-9.2-workaround
Browse files Browse the repository at this point in the history
Simplify JRuby version check
  • Loading branch information
mislav committed Jun 11, 2024
2 parents 96d5ce2 + fb1b4da commit 5e23d85
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 5 deletions.
6 changes: 2 additions & 4 deletions bin/ruby-build
Original file line number Diff line number Diff line change
Expand Up @@ -860,7 +860,7 @@ build_package_jruby() {
cd "${PREFIX_PATH}/bin"
ln -fs jruby ruby
chmod +x ruby
install_jruby_launcher
install_jruby_launcher "$1"
remove_windows_files
fix_jruby_shebangs
}
Expand All @@ -869,9 +869,7 @@ install_jruby_launcher() {
# shellcheck disable=SC2164
cd "${PREFIX_PATH}/bin"
# workaround for https://github.com/jruby/jruby/issues/7799
local jruby_version
jruby_version="$(./ruby -e 'puts JRUBY_VERSION' 2>/dev/null)"
[[ $jruby_version != "9.2."* ]] ||
[[ $1 != "jruby-9.2."* ]] ||
capture_command ./ruby gem update -q --silent --system 3.3.26 --no-document --no-post-install-message
capture_command ./ruby gem install jruby-launcher --no-document
}
Expand Down
1 change: 0 additions & 1 deletion test/build.bats
Original file line number Diff line number Diff line change
Expand Up @@ -848,7 +848,6 @@ DEF
assert_success

assert_build_log <<OUT
jruby [-e,puts JRUBY_VERSION]
jruby [gem,install,jruby-launcher,--no-document]
OUT

Expand Down

0 comments on commit 5e23d85

Please sign in to comment.