Skip to content

Commit

Permalink
Speedup GitHub workflow (#816)
Browse files Browse the repository at this point in the history
  • Loading branch information
albig authored Feb 26, 2025
1 parent c002efc commit 1369656
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 2 deletions.
10 changes: 10 additions & 0 deletions .github/workflows/build-deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,17 @@ jobs:
with:
node-version: ${{ env.NODE_VERSION }}

- name: Cache node_modules directory
uses: actions/cache@v4
id: npm-cache-dir
with:
path: node_modules
key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }}
restore-keys: |
${{ runner.os }}-node-
- name: Install npm packages
if: steps.npm-cache-dir.outputs.cache-hit != 'true'
run: npm ci

- name: Build CSS
Expand Down
6 changes: 4 additions & 2 deletions .github/workflows/build-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,15 +31,17 @@ jobs:
with:
node-version: ${{ env.NODE_VERSION }}

- name: Cache .npm directory
- name: Cache node_modules directory
uses: actions/cache@v4
id: npm-cache-dir
with:
path: ~/.npm
path: node_modules
key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }}
restore-keys: |
${{ runner.os }}-node-
- name: Install npm packages
if: steps.npm-cache-dir.outputs.cache-hit != 'true'
run: npm ci

- name: Lint SCSS
Expand Down

0 comments on commit 1369656

Please sign in to comment.