From c68a6d9342574c6f74a228caf31cba83e71ef683 Mon Sep 17 00:00:00 2001 From: Hiroshi SHIBATA Date: Fri, 3 Jun 2022 19:13:53 +0900 Subject: [PATCH 1/2] Update Ruby versions on GHA with ci_versions/all.json --- .github/workflows/test.yml | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 5416484..cd82e82 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -3,11 +3,21 @@ name: test on: [push, pull_request] jobs: - build: + ruby-versions: + runs-on: ubuntu-latest + outputs: + versions: ${{ steps.versions.outputs.value }} + steps: + - id: versions + run: | + versions=$(curl -s 'https://cache.ruby-lang.org/pub/misc/ci_versions/all.json' | jq -c '. - ["2.7"]') + echo "::set-output name=value::${versions}" + test: + needs: ruby-versions name: build (${{ matrix.ruby }} / ${{ matrix.os }}) strategy: matrix: - ruby: [ head ] + ruby: ${{ fromJson(needs.ruby-versions.outputs.versions) }} os: [ ubuntu-latest, macos-latest ] runs-on: ${{ matrix.os }} steps: From d0f0be1b630bd2c3376f40b0d47dafcbedeeb223 Mon Sep 17 00:00:00 2001 From: Hiroshi SHIBATA Date: Fri, 3 Jun 2022 19:15:35 +0900 Subject: [PATCH 2/2] delegate is only working with CRuby --- .github/workflows/test.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index cd82e82..519fd8a 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -10,7 +10,7 @@ jobs: steps: - id: versions run: | - versions=$(curl -s 'https://cache.ruby-lang.org/pub/misc/ci_versions/all.json' | jq -c '. - ["2.7"]') + versions=$(curl -s 'https://cache.ruby-lang.org/pub/misc/ci_versions/cruby.json' | jq -c '. - ["2.7"]') echo "::set-output name=value::${versions}" test: needs: ruby-versions