Skip to content

Commit

Permalink
ci: simplify caching mechanism
Browse files Browse the repository at this point in the history
  • Loading branch information
merlinnot committed Feb 5, 2020
1 parent 3992dd2 commit be0e181
Showing 1 changed file with 2 additions and 14 deletions.
16 changes: 2 additions & 14 deletions .github/workflows/continuous-integration.yaml
Expand Up @@ -96,24 +96,12 @@ jobs:
id: npm-cache
run: |
echo "::set-output name=dir::$(npm config get cache)"
# The following two steps can be greatly simplified once
# https://github.com/actions/cache/issues/39 is fixed.
- if: runner.os != 'Windows'
name: Cache npm dependencies
uses: actions/cache@v1
with:
path: ${{ steps.npm-cache.outputs.dir }}
key: |
npm-${{ runner.os }}-${{ hashFiles('**/package-lock.json') }}
restore-keys: |
npm-${{ runner.os }}-
- if: runner.os == 'Windows'
name: Cache npm dependencies
- name: Cache npm dependencies
uses: actions/cache@v1
with:
path: ${{ steps.npm-cache.outputs.dir }}
key: |
npm-${{ runner.os }}-${{ hashFiles('**\package-lock.json') }}
npm-${{ runner.os }}-${{ hashFiles('./package-lock.json') }}
restore-keys: |
npm-${{ runner.os }}-
- name: Install dependencies
Expand Down

0 comments on commit be0e181

Please sign in to comment.