diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 4085056..3a6d99b 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -29,6 +29,9 @@ jobs: - rails_7.0.8 - rails_6.1.7 + env: # $BUNDLE_GEMFILE must be set at the job level, so it is set for all steps + BUNDLE_GEMFILE: ${{ github.workspace }}/gemfiles/${{ matrix.rails }}.gemfile + steps: - name: Checkout uses: actions/checkout@v4 @@ -37,21 +40,11 @@ jobs: uses: ruby/setup-ruby@v1 with: ruby-version: ${{ matrix.ruby }} - - - name: Bundle - env: - RAILS_VERSION: ${{ matrix.rails }} - BUNDLE_GEMFILE: gemfiles/${{ matrix.rails }}.gemfile - run: | - gem install bundler - bundle config path vendor/bundle - bundle install --jobs 4 --retry 3 + bundler-cache: true - name: RSpec & publish code coverage uses: paambaati/codeclimate-action@v8.0.0 env: - RAILS_VERSION: ${{ matrix.rails }} - BUNDLE_GEMFILE: gemfiles/${{ matrix.rails }}.gemfile CC_TEST_REPORTER_ID: ${{ secrets.CC_TEST_REPORTER_ID }} with: coverageCommand: bin/rake