Skip to content

Commit f83b049

Browse files
committed
CI: Use latest npm in all jobs
1 parent d261104 commit f83b049

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

.circleci/config.yml

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,13 @@ commands:
2222
name: Versions
2323
command: npm version
2424

25+
update-npm:
26+
steps:
27+
- run:
28+
name: Update globally available npm to the latest version
29+
# Note: We need npm >= 8.3 which supports 'overrides' in package.json
30+
command: sudo npm install npm --global
31+
2532
install-dependencies:
2633
parameters:
2734
cache-id:
@@ -148,6 +155,7 @@ jobs:
148155
type: boolean
149156
default: false
150157
steps:
158+
# We want the default npm here. Older one might not work with older node.js
151159
- show-npm-version
152160
- checkout
153161
- install-dependencies:
@@ -172,6 +180,7 @@ jobs:
172180
docker:
173181
- image: circleci/node:16
174182
steps:
183+
- update-npm
175184
- show-npm-version
176185
- provision-and-package-solcjs
177186
- provision-hardhat-with-packaged-solcjs
@@ -188,6 +197,7 @@ jobs:
188197
docker:
189198
- image: circleci/node:16
190199
steps:
200+
- update-npm
191201
- show-npm-version
192202
- provision-and-package-solcjs
193203
- provision-hardhat-with-packaged-solcjs
@@ -205,6 +215,7 @@ jobs:
205215
docker:
206216
- image: circleci/node:16
207217
steps:
218+
- update-npm
208219
- show-npm-version
209220
- provision-and-package-solcjs
210221
- run: git clone --depth 1 "https://github.com/nomiclabs/hardhat-hackathon-boilerplate" boilerplate/
@@ -258,6 +269,7 @@ jobs:
258269
docker:
259270
- image: circleci/node:12
260271
steps:
272+
- update-npm
261273
- show-npm-version
262274
- provision-and-package-solcjs
263275
- provision-truffle-with-packaged-solcjs

0 commit comments

Comments
 (0)