Fix check for TruffleRuby < 21.0 and Bundler 1

This commit is contained in:
Benoit Daloze
2021-07-27 13:35:24 +02:00
parent 0c7e9c4d53
commit 0997e21bf3
3 changed files with 13 additions and 4 deletions
+4
View File
@@ -55,6 +55,10 @@ export function isStableVersion(rubyVersion) {
return /^\d+(\.\d+)*$/.test(rubyVersion)
}
export function isBundler1Default(engine, rubyVersion) {
return !isBundler2Default(engine, rubyVersion)
}
export function isBundler2Default(engine, rubyVersion) {
if (engine === 'ruby') {
return isHeadVersion(rubyVersion) || floatVersion(rubyVersion) >= 2.7