mirror of
https://github.com/ruby/setup-ruby.git
synced 2026-09-13 14:34:21 +02:00
Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
87ccb7599f | ||
|
|
19b31c7064 |
@@ -96,19 +96,33 @@ jobs:
|
||||
- run: bundle exec rake --version
|
||||
- run: bundle exec rake
|
||||
|
||||
# Ensure the same bundle commands work in bash on Windows
|
||||
- name: bundle install (bash)
|
||||
run: bundle install
|
||||
shell: bash
|
||||
if: startsWith(matrix.os, 'windows')
|
||||
- name: bundle exec rake --version (bash)
|
||||
run: bundle exec rake --version
|
||||
shell: bash
|
||||
if: startsWith(matrix.os, 'windows')
|
||||
- name: bundle exec rake (bash)
|
||||
run: bundle exec rake
|
||||
shell: bash
|
||||
if: startsWith(matrix.os, 'windows')
|
||||
|
||||
- name: Test `gem github:` in a Gemfile
|
||||
run: bundle install
|
||||
env:
|
||||
BUNDLE_GEMFILE: ${{ github.workspace }}/gemfiles/gem_from_github.gemfile
|
||||
|
||||
- name: which ruby, rake
|
||||
- name: which ruby, rake bundle
|
||||
if: "!startsWith(matrix.os, 'windows')"
|
||||
run: which -a ruby rake
|
||||
- name: where ruby, rake
|
||||
run: which -a ruby rake bundle
|
||||
- name: where ruby, rake, bundle
|
||||
if: startsWith(matrix.os, 'windows')
|
||||
run: |
|
||||
$ErrorActionPreference = 'Continue'
|
||||
$where = 'ruby', 'rake'
|
||||
$where = 'ruby', 'rake', 'bundle'
|
||||
foreach ($e in $where) {
|
||||
$rslt = where.exe $e 2>&1 | Out-String
|
||||
if ($rslt.contains($e)) { echo $rslt.Trim() }
|
||||
@@ -117,7 +131,7 @@ jobs:
|
||||
}
|
||||
- name: bash test
|
||||
shell: bash
|
||||
run: echo ~
|
||||
run: echo ~ && bundle install
|
||||
- name: Windows JRuby
|
||||
if: startsWith(matrix.os, 'windows') && startsWith(matrix.ruby, 'jruby')
|
||||
run: gem install sassc
|
||||
|
||||
+8
-2
@@ -72,8 +72,14 @@ export async function installBundler(bundlerVersionInput, rubygemsInputSet, lock
|
||||
|
||||
if (bundlerVersion === 'default') {
|
||||
if (common.isBundler2dot2Default(engine, rubyVersion)) {
|
||||
console.log(`Using Bundler 2 shipped with ${engine}-${rubyVersion}`)
|
||||
return '2'
|
||||
if (common.windows && engine === 'ruby') {
|
||||
// https://github.com/ruby/setup-ruby/issues/371
|
||||
console.log(`Installing latest Bundler for ${engine}-${rubyVersion} on Windows because bin/bundle does not work in bash otherwise`)
|
||||
bundlerVersion = 'latest'
|
||||
} else {
|
||||
console.log(`Using Bundler 2 shipped with ${engine}-${rubyVersion}`)
|
||||
return '2'
|
||||
}
|
||||
} else if (common.hasBundlerDefaultGem(engine, rubyVersion)) {
|
||||
// Those Rubies have a old Bundler default gem < 2.2 which does not work well for `gem 'foo', github: 'foo/foo'`:
|
||||
// https://github.com/ruby/setup-ruby/issues/358#issuecomment-1195899304
|
||||
|
||||
+8
-2
@@ -86,8 +86,14 @@ async function installBundler(bundlerVersionInput, rubygemsInputSet, lockFile, p
|
||||
|
||||
if (bundlerVersion === 'default') {
|
||||
if (common.isBundler2dot2Default(engine, rubyVersion)) {
|
||||
console.log(`Using Bundler 2 shipped with ${engine}-${rubyVersion}`)
|
||||
return '2'
|
||||
if (common.windows && engine === 'ruby') {
|
||||
// https://github.com/ruby/setup-ruby/issues/371
|
||||
console.log(`Installing latest Bundler for ${engine}-${rubyVersion} on Windows because bin/bundle does not work in bash otherwise`)
|
||||
bundlerVersion = 'latest'
|
||||
} else {
|
||||
console.log(`Using Bundler 2 shipped with ${engine}-${rubyVersion}`)
|
||||
return '2'
|
||||
}
|
||||
} else if (common.hasBundlerDefaultGem(engine, rubyVersion)) {
|
||||
// Those Rubies have a old Bundler default gem < 2.2 which does not work well for `gem 'foo', github: 'foo/foo'`:
|
||||
// https://github.com/ruby/setup-ruby/issues/358#issuecomment-1195899304
|
||||
|
||||
Reference in New Issue
Block a user