From d9e5730f40759986b5cb665e420d43eac3939805 Mon Sep 17 00:00:00 2001 From: Hiroshi SHIBATA Date: Tue, 31 May 2022 21:14:45 +0900 Subject: [PATCH 1/4] Use https://cache.ruby-lang.org/pub/misc/ci_versions.json --- .github/workflows/test.yml | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index d37898e..e7ed2e0 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -3,11 +3,21 @@ name: test on: [push, pull_request] jobs: + 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.json' | jq -c) + echo "::set-output name=value::${versions}" build: + needs: ruby-versions name: build (${{ matrix.ruby }} / ${{ matrix.os }}) strategy: matrix: - ruby: [ '3.0', 2.7, 2.6, 2.5, 2.4, head ] + ruby: ${{fromJson(needs.ruby-versions.outputs.versions)}} os: [ ubuntu-latest, macos-latest ] runs-on: ${{ matrix.os }} steps: From 83eb622c28b99d5f391ca7346c7b26c76468c150 Mon Sep 17 00:00:00 2001 From: Hiroshi SHIBATA Date: Thu, 2 Jun 2022 09:34:44 +0900 Subject: [PATCH 2/4] style --- .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 e7ed2e0..6296869 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -17,7 +17,7 @@ jobs: name: build (${{ matrix.ruby }} / ${{ matrix.os }}) strategy: matrix: - ruby: ${{fromJson(needs.ruby-versions.outputs.versions)}} + ruby: ${{ fromJson(needs.ruby-versions.outputs.versions) }} os: [ ubuntu-latest, macos-latest ] runs-on: ${{ matrix.os }} steps: From 3e4eec77eec37fb3262251f0a23562b24228682f Mon Sep 17 00:00:00 2001 From: Hiroshi SHIBATA Date: Thu, 2 Jun 2022 09:34:53 +0900 Subject: [PATCH 3/4] Rename job name --- .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 6296869..d55ac4e 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -12,7 +12,7 @@ jobs: run: | versions=$(curl -s 'https://cache.ruby-lang.org/pub/misc/ci_versions.json' | jq -c) echo "::set-output name=value::${versions}" - build: + test: needs: ruby-versions name: build (${{ matrix.ruby }} / ${{ matrix.os }}) strategy: From 5beacffecaa86594316d67586f9e12f2cb4861e0 Mon Sep 17 00:00:00 2001 From: Hiroshi SHIBATA Date: Thu, 2 Jun 2022 09:35:08 +0900 Subject: [PATCH 4/4] Try with all rubies --- .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 d55ac4e..b244cb7 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.json' | jq -c) + versions=$(curl -s 'https://cache.ruby-lang.org/pub/misc/ci_versions/all.json' | jq -c) echo "::set-output name=value::${versions}" test: needs: ruby-versions