update actions/cache to v2 for gh workflows (#1314)

Signed-off-by: Matthew Peveler <matt.peveler@gmail.com>
This commit is contained in:
Matthew Peveler
2020-09-10 12:47:29 -04:00
committed by GitHub
parent 7441d83562
commit db503c93fe
3 changed files with 26 additions and 8 deletions

View File

@@ -21,16 +21,22 @@ jobs:
with:
ruby-version: ${{ matrix.ruby-version }}
- uses: actions/cache@v1
- uses: actions/cache@v2
with:
path: vendor/bundle
key: gems-${{ runner.os }}-${{ matrix.ruby-version }}-${{ hashFiles('**/Gemfile.lock') }}
restore-keys: |
gems-${{ runner.os }}-${{ matrix.ruby-version }}-
gems-${{ runner.os }}-
# necessary to get ruby 2.3 to work nicely with bundler vendor/bundle cache
# can remove once ruby 2.3 is no longer supported
- run: gem update --system
- run: bundle config set deployment 'true'
- run: bundle install
- name: bundle install
run: |
bundle config path vendor/bundle
bundle install --jobs 4 --retry 3
- run: bundle exec middleman build

View File

@@ -17,13 +17,19 @@ jobs:
with:
ruby-version: ${{ env.ruby-version }}
- uses: actions/cache@v1
- uses: actions/cache@v2
with:
path: vendor/bundle
key: gems-${{ runner.os }}-${{ env.ruby-version }}-${{ hashFiles('**/Gemfile.lock') }}
key: gems-${{ runner.os }}-${{ matrix.ruby-version }}-${{ hashFiles('**/Gemfile.lock') }}
restore-keys: |
gems-${{ runner.os }}-${{ matrix.ruby-version }}-
gems-${{ runner.os }}-
- run: bundle config set deployment 'true'
- run: bundle install
- name: bundle install
run: |
bundle config path vendor/bundle
bundle install --jobs 4 --retry 3
- run: bundle exec middleman build

View File

@@ -17,13 +17,19 @@ jobs:
with:
ruby-version: ${{ env.ruby-version }}
- uses: actions/cache@v1
- uses: actions/cache@v2
with:
path: vendor/bundle
key: gems-${{ runner.os }}-${{ env.ruby-version }}-${{ hashFiles('**/Gemfile.lock') }}
key: gems-${{ runner.os }}-${{ matrix.ruby-version }}-${{ hashFiles('**/Gemfile.lock') }}
restore-keys: |
gems-${{ runner.os }}-${{ matrix.ruby-version }}-
gems-${{ runner.os }}-
- run: bundle config set deployment 'true'
- run: bundle install
- name: bundle install
run: |
bundle config path vendor/bundle
bundle install --jobs 4 --retry 3
- run: bundle exec middleman build