Skip to content

Commit

Permalink
chore: npm cache
Browse files Browse the repository at this point in the history
  • Loading branch information
web-mi committed Feb 2, 2024
1 parent 560a754 commit 2a0ea44
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 4 deletions.
9 changes: 7 additions & 2 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,12 +32,17 @@ jobs:
node-version: 18
registry-url: 'https://npm.pkg.github.com'
cache: 'npm'
- name: Get npm cache directory
id: npm-cache-dir
shell: bash
run: echo "dir=$(npm config get cache)" >> ${GITHUB_OUTPUT}
- name: Cache npm dependencies
uses: actions/cache@v4
with:
path: ~/.npm
path: ${{ steps.npm-cache-dir.outputs.dir }}
key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }}
restore-keys: ${{ runner.os }}-node-
restore-keys: |
${{ runner.os }}-node-
- name: Load .env file
uses: xom9ikk/dotenv@v2
with:
Expand Down
9 changes: 7 additions & 2 deletions .github/workflows/dockerImage.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,12 +36,17 @@ jobs:
with:
node-version: 18
cache: 'npm'
- name: Get npm cache directory
id: npm-cache-dir
shell: bash
run: echo "dir=$(npm config get cache)" >> ${GITHUB_OUTPUT}
- name: Cache npm dependencies
uses: actions/cache@v4
with:
path: ~/.npm
path: ${{ steps.npm-cache-dir.outputs.dir }}
key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }}
restore-keys: ${{ runner.os }}-node-
restore-keys: |
${{ runner.os }}-node-
- name: Load .env file
uses: xom9ikk/dotenv@v2
with:
Expand Down

0 comments on commit 2a0ea44

Please sign in to comment.