Skip to content

Commit

Permalink
ci/cd: experiments with caching
Browse files Browse the repository at this point in the history
  • Loading branch information
kamilsk committed Apr 1, 2023
1 parent f2dee4e commit f634182
Showing 1 changed file with 11 additions and 2 deletions.
13 changes: 11 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -54,9 +54,18 @@ jobs:
- name: Checkout the repository
uses: actions/checkout@v3
with: { fetch-depth: 0 }

- name: Set up Node.js environment
uses: actions/setup-node@v3
with: { node-version: 16, cache: npm }
- name: Install application dependencies if needed
run: npm ci --ignore-scripts --include=dev

- name: Set up Node.js environment
uses: actions/setup-node@v3
with: { node-version: 16, cache: npm, cache-dependency-path: tools/package-lock.json }
- name: Install tooling dependencies if needed
run: ./Taskfile tools npm ci

# https://github.com/actions/setup-node/blob/main/docs/advanced-usage.md#caching-packages-data
# - name: Cache tooling dependencies
Expand All @@ -65,8 +74,8 @@ jobs:
# with:
# path: ./tools/node_modules
# key: tools-${{ hashFiles('tools/package-lock.json') }}
- name: Install tooling dependencies if needed
run: ./Taskfile tools npm ci
# - name: Install tooling dependencies if needed
# run: ./Taskfile tools npm ci
# if: steps.tools.outputs.cache-hit != 'true'
- name: Check application dependencies
run: 'source bin/activate && [ "$(./Taskfile @deps check)" == "No depcheck issue" ]'
Expand Down

0 comments on commit f634182

Please sign in to comment.