Skip to content

Commit

Permalink
Feat/arch nvm cache (#238)
Browse files Browse the repository at this point in the history
* Add arch to the cache for nvm

* update cache key
  • Loading branch information
marboledacci authored Dec 2, 2024
1 parent 792c314 commit 84232a2
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
6 changes: 3 additions & 3 deletions .circleci/test-deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ jobs:
node-version: "16.13"
install-yarn: true # Test the install of YARN
yarn-version: "1.22.5"
nvm-cache-key: v2-<<parameters.os>>
nvm-cache-key: v2
- run:
command: |
if ! node --version | grep -q "16"; then
Expand All @@ -57,7 +57,7 @@ jobs:
- node/install:
install-pnpm: true # Test the install of PNPM
pnpm-version: "9.7.1"
nvm-cache-key: v2-lts-<<parameters.os>>
nvm-cache-key: v2-{{ arch }}
- run:
command: |
if ! pnpm --version | grep -q "9.7.1"; then
Expand All @@ -78,7 +78,7 @@ jobs:
- checkout
- node/install:
node-version: "latest"
nvm-cache-key: v2-latest-<<parameters.os>>
nvm-cache-key: v2
- run:
name: Check that latest Node.js is installed.
command: |
Expand Down
4 changes: 2 additions & 2 deletions src/commands/install.yml
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ steps:
- restore_cache:
name: Restore Nvm Cache
keys:
- <<parameters.nvm-cache-key>>-<<parameters.node-version>>
- <<parameters.nvm-cache-key>>-<<parameters.node-version>>-{{ arch }}
- run:
name: Install Node.js <<parameters.node-version>>
environment:
Expand All @@ -75,7 +75,7 @@ steps:
steps:
- save_cache:
name: Save Nvm Cache
key: <<parameters.nvm-cache-key>>-<<parameters.node-version>>
key: <<parameters.nvm-cache-key>>-<<parameters.node-version>>-{{ arch }}
paths:
- ~/.nvm/.cache
- /opt/circleci/.nvm/.cache
Expand Down

0 comments on commit 84232a2

Please sign in to comment.