Skip to content

Commit

Permalink
feat(13-caching): add caching for dependencies
Browse files Browse the repository at this point in the history
  • Loading branch information
lauromueller committed Nov 11, 2023
1 parent b7e5185 commit a39fae6
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions .github/workflows/13-caching.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,15 @@ jobs:
uses: actions/setup-node@v3
with:
node-version: ${{ inputs.node-version }}
- name: Download cached dependencies
uses: actions/cache@v3
if: ${{ inputs.use-cache }}
id: cache
with:
path: 13-caching/react-app/node_modules
key: deps-node-modules-${{ hashFiles('13-caching/react-app/package-lock.json') }}
- name: Install dependencies
if: steps.cache.outputs.cache-hit != 'true'
run: npm ci
- name: Testing
run: npm run test
Expand Down

0 comments on commit a39fae6

Please sign in to comment.