ci: use ruby/setup-ruby for both builds
Currently macOS is using rvm as the previous `actions/setup-ruby` did not work
there at the time were building this. This change should speed up and unify the
versions we run for our tests.
@@ -12,7 +12,7 @@ jobs:
strategy:
fail-fast: false
matrix:
- ruby: [ '2.4.9', '2.5.7', '2.6.5', '2.7.0' ]
+ ruby: [ '2.6', '2.7', '3.0' ]
os: [ macOS-latest ]
runs-on: ${{ matrix.os }}
@@ -24,10 +24,10 @@ jobs:
- name: Install macOS packages
run: ./vendor/libgit2/ci/setup-osx.sh
- name: Set up Ruby on macOS
- run: |
- brew install rbenv
- rbenv install ${{ matrix.ruby }}
- rbenv local ${{ matrix.ruby }}
+ uses: ruby/setup-ruby@v1
+ with:
+ ruby-version: ${{ matrix.ruby }}
+ bundler-cache: true
- name: run build
run: |
eval "$(rbenv init -)"
@@ -40,7 +40,7 @@ jobs:
strategy:
fail-fast: false
matrix:
- ruby: [ '2.4', '2.5', '2.6', '2.7' ]
+ ruby: [ '2.6', '2.7', '3.0' ]
os: [ ubuntu-18.04 ]
runs-on: ${{ matrix.os }}
@@ -54,9 +54,10 @@ jobs:
sudo apt update
sudo apt install -y cmake libssh2-1-dev openssh-client openssh-server
- name: Set up Ruby on Linux
- uses: actions/setup-ruby@v1
+ uses: ruby/setup-ruby@v1
with:
ruby-version: ${{ matrix.ruby }}
+ bundler-cache: true
- name: run build
run: |
ruby --version
