Skip to content

Commit

Permalink
CI performance improvements
Browse files Browse the repository at this point in the history
Enable `bundler-cache` - ref: https://github.com/ruby/setup-ruby#caching-bundle-install-automatically
Use `MAKE` env var to improve building native extensions on MRI - ref: https://build.betterup.com/one-weird-trick-that-will-speed-up-your-bundle-install/
  • Loading branch information
codealchemy committed Aug 16, 2021
1 parent 2831243 commit cae65a4
Showing 1 changed file with 5 additions and 9 deletions.
14 changes: 5 additions & 9 deletions .github/workflows/test.yml
Expand Up @@ -67,15 +67,11 @@ jobs:
uses: ruby/setup-ruby@v1
with:
ruby-version: ${{ matrix.ruby }}
- name: Cache gems
uses: actions/cache@v2
with:
path: vendor/bundle
key: ${{ runner.os }}-gems-${{ matrix.ruby }}-${{ hashFiles('Gemfile', 'gemfiles/*.gemfile') }}
restore-keys: |
${{ runner.os }}-gems-${{ matrix.ruby }}-
- name: Install dependencies
run: bundle install --without development --jobs=3 --retry=3 --path=vendor/bundle
bundler-cache: true
cache-version: gems-${{ hashFiles('Gemfile', 'gemfiles/*.gemfile') }}
env:
MAKE: make --jobs 4
BUNDLE_WITHOUT: development
- name: Setup application
env:
BUNDLE_GEMFILE: ../../${{ matrix.gemfile }}
Expand Down

0 comments on commit cae65a4

Please sign in to comment.