From b839deb3a8f673f3d1a40ff591856f90771b4763 Mon Sep 17 00:00:00 2001 From: Ashwin Maroli Date: Wed, 11 Jan 2023 20:50:44 +0530 Subject: [PATCH 1/3] Use cache built into `ruby/setup-ruby` action --- .github/workflows/liquid.yml | 23 ++++++++++------------- 1 file changed, 10 insertions(+), 13 deletions(-) diff --git a/.github/workflows/liquid.yml b/.github/workflows/liquid.yml index 749eee0a4..c9ab4773f 100644 --- a/.github/workflows/liquid.yml +++ b/.github/workflows/liquid.yml @@ -1,5 +1,11 @@ name: Liquid on: [push, pull_request] + +env: + BUNDLE_PATH: "vendor/bundle" + BUNDLE_JOBS: 4 + BUNDLE_RETRY: 3 + jobs: test: runs-on: ubuntu-latest @@ -9,20 +15,16 @@ jobs: - { ruby: 2.7, allowed-failure: false } # minimum supported - { ruby: 3.1, allowed-failure: false } # latest - { ruby: ruby-head, allowed-failure: true } - name: test (${{ matrix.entry.ruby }}) + name: Test Ruby ${{ matrix.entry.ruby }} steps: - uses: actions/checkout@v3 - uses: ruby/setup-ruby@v1 with: ruby-version: ${{ matrix.entry.ruby }} - - uses: actions/cache@v1 - with: - path: vendor/bundle - key: ${{ runner.os }}-gems-${{ hashFiles('Gemfile') }} - restore-keys: ${{ runner.os }}-gems- - - run: bundle install --jobs=3 --retry=3 --path=vendor/bundle + bundler-cache: true - run: bundle exec rake continue-on-error: ${{ matrix.entry.allowed-failure }} + memory_profile: runs-on: ubuntu-latest steps: @@ -30,10 +32,5 @@ jobs: - uses: ruby/setup-ruby@v1 with: ruby-version: 2.7 - - uses: actions/cache@v1 - with: - path: vendor/bundle - key: ${{ runner.os }}-gems-${{ hashFiles('Gemfile') }} - restore-keys: ${{ runner.os }}-gems- - - run: bundle install --jobs=3 --retry=3 --path=vendor/bundle + bundler-cache: true - run: bundle exec rake memory_profile:run From 1beb87b4460876b0dc5709bbcc663718acbb0bcc Mon Sep 17 00:00:00 2001 From: Ashwin Maroli Date: Wed, 11 Jan 2023 20:58:17 +0530 Subject: [PATCH 2/3] Bump latest Ruby version in CI matrix --- .github/workflows/liquid.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/liquid.yml b/.github/workflows/liquid.yml index c9ab4773f..fc44648f9 100644 --- a/.github/workflows/liquid.yml +++ b/.github/workflows/liquid.yml @@ -13,7 +13,7 @@ jobs: matrix: entry: - { ruby: 2.7, allowed-failure: false } # minimum supported - - { ruby: 3.1, allowed-failure: false } # latest + - { ruby: 3.2, allowed-failure: false } # latest - { ruby: ruby-head, allowed-failure: true } name: Test Ruby ${{ matrix.entry.ruby }} steps: From 6a44c1ec772167f612fbb3dcef02bbb5c9682d8f Mon Sep 17 00:00:00 2001 From: Ashwin Maroli Date: Wed, 11 Jan 2023 22:06:47 +0530 Subject: [PATCH 3/3] Do not set `ENV["BUNDLE_PATH"]` --- .github/workflows/liquid.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/liquid.yml b/.github/workflows/liquid.yml index fc44648f9..7dc744325 100644 --- a/.github/workflows/liquid.yml +++ b/.github/workflows/liquid.yml @@ -2,7 +2,6 @@ name: Liquid on: [push, pull_request] env: - BUNDLE_PATH: "vendor/bundle" BUNDLE_JOBS: 4 BUNDLE_RETRY: 3