Skip to content

Commit

Permalink
Merge pull request #41 from r7kamura/npm-cache-ci
Browse files Browse the repository at this point in the history
Improve CI npm cache
  • Loading branch information
r7kamura committed Dec 24, 2023
2 parents 3db2169 + 90d5bca commit 1105cca
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,14 @@ jobs:
- uses: actions/setup-node@v3
with:
node-version-file: package.json
cache: npm
- run: npm install
- id: cache-node-modules
uses: actions/cache@v3
with:
path: node_modules
key: node-modules-${{ runner.os }}-${{ hashFiles('.node-version') }}-${{ hashFiles('package-lock.json') }}
restore-keys: node-modules-${{ runner.os }}-${{ hashFiles('.node-version') }}-${{ hashFiles('package-lock.json') }}
- if: steps.cache-node-modules.outputs.cache-hit != 'true'
run: npm ci
- run: npm run export
env:
ARTICLES_DIRECTORY_PATHS: ./r7kamura.com/articles
Expand Down

0 comments on commit 1105cca

Please sign in to comment.