Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Tags: ruby/setup-ruby

Tags

v1.267.0

Toggle v1.267.0's commit message
exec.exec() only accepts strings

v1.266.0

Toggle v1.266.0's commit message
Update CRuby releases on Windows

v1.265.0

Toggle v1.265.0's commit message
Update CRuby releases on Windows

v1.264.0

Toggle v1.264.0's commit message
Add ruby-3.4.7

v1.263.0

Toggle v1.263.0's commit message
Print lockfile contents earlier

Currently, the lockfile gets printed after `bundle install` finished. This could be too late when `bundle install` fails for whatever reason.

I have a workflow that failed like this:

<details><summary>Logs</summary>
<p>

```

55s
Run ruby/setup-ruby@v1
Modifying PATH
Downloading Ruby
Extracting  Ruby
Print Ruby version
Installing Bundler
> bundle install
/opt/hostedtoolcache/Ruby/2.7.8/x64/bin/bundle config --local path /home/runner/work/rubocop/rubocop/vendor/bundle
/opt/hostedtoolcache/Ruby/2.7.8/x64/bin/bundle lock
Fetching source index from https://rubygems.org/
Network error while fetching
https://rubygems.org/quick/Marshal.4.8/asciidoctor-0.0.1.gemspec.rz (Connection
reset by peer - SSL_connect)
Error: The process '/opt/hostedtoolcache/Ruby/2.7.8/x64/bin/bundle' failed with exit code 17
Run ruby/setup-ruby@v1
Modifying PATH
Downloading Ruby
Extracting  Ruby
Print Ruby version
Installing Bundler
> bundle install
/opt/hostedtoolcache/Ruby/2.7.8/x64/bin/bundle config --local path /home/runner/work/rubocop/rubocop/vendor/bundle
/opt/hostedtoolcache/Ruby/2.7.8/x64/bin/bundle lock
Fetching source index from https://rubygems.org/
Network error while fetching
https://rubygems.org/quick/Marshal.4.8/asciidoctor-0.0.1.gemspec.rz (Connection
reset by peer - SSL_connect)
Error: The process '/opt/hostedtoolcache/Ruby/2.7.8/x64/bin/bundle' failed with exit code 17
```

</p>
</details>

It would help to print the lockfile for this I think. It fetching version 0.0.1 confused me but probably the lockfile looks ok. New output:

```
Run ./
Modifying PATH
Print Ruby version
Installing Bundler
> bundle install
/opt/hostedtoolcache/Ruby/3.2.9/x64/bin/bundle config --local path /home/runner/work/setup-ruby/setup-ruby/vendor/bundle
/opt/hostedtoolcache/Ruby/3.2.9/x64/bin/bundle lock
Fetching gem metadata from https://rubygems.org/...........
Resolving dependencies...
Writing lockfile to /home/runner/work/setup-ruby/setup-ruby/gemfiles/rails8.gemfile.lock
Print lockfile
Cache key: setup-ruby-bundler-cache-v6-ubuntu-24.04-x64-ruby-3.2.9-wd-/home/runner/work/setup-ruby/setup-ruby-with--without--only--/home/runner/work/setup-ruby/setup-ruby/gemfiles/rails8.gemfile.lock-cb69172094f71f01e5207070d9af8d465d9aa9c386ecbad22b1b6e8e43523fd2
/opt/hostedtoolcache/Ruby/3.2.9/x64/bin/bundle install --jobs 4
...
```

So it's relatively at the top and not hidden somewhere. Also removes the need to check for the lockfile again.

v1.262.0

Toggle v1.262.0's commit message
Use new releases of ruby-builder per engine-version

* See #810

v1.261.0

Toggle v1.261.0's commit message
Update CRuby releases on Windows

v1.260.0

Toggle v1.260.0's commit message
Test on JRuby 9.4 as well as 10.0

v1.259.0

Toggle v1.259.0's commit message
chore: add setup-node for lint job

Signed-off-by: Rui Chen <[email protected]>

v1.258.0

Toggle v1.258.0's commit message
Add truffleruby-25.0.0,truffleruby+graalvm-25.0.0