@@ -73,13 +73,13 @@ jobs:
73
73
- name : Use Node.js
74
74
uses : actions/setup-node@v4
75
75
with :
76
- node-version : 20
77
- registry-url : ' https://registry.npmjs.org '
76
+ cache : yarn
77
+ node-version-file : .nvmrc
78
78
79
- - run : npm ci
79
+ - run : yarn install
80
80
- run : opam install dune cppo
81
- - run : npm run compile
82
- - run : npm run bundle
81
+ - run : yarn compile
82
+ - run : yarn bundle
83
83
84
84
# These 2 runs (or just the second?) are for when you have opam dependencies. We don't.
85
85
# Don't add deps. But if you ever do, un-comment these and add an .opam file.
@@ -124,11 +124,11 @@ jobs:
124
124
- name : Use Node.js
125
125
uses : actions/setup-node@v4
126
126
with :
127
- node-version : 20
128
- registry-url : ' https://registry.npmjs.org '
127
+ cache : yarn
128
+ node-version-file : .nvmrc
129
129
130
- - run : npm ci
131
- - run : npm run compile
130
+ - run : yarn install
131
+ - run : yarn compile
132
132
133
133
- name : Download MacOS binaries
134
134
uses : actions/download-artifact@v4
@@ -209,15 +209,15 @@ jobs:
209
209
210
210
- name : Package Extension
211
211
if : github.ref != 'refs/heads/master'
212
- run : npx vsce package -o rescript-vscode-${{ steps.vars.outputs.sha_short }}.vsix
212
+ run : yarn dlx vsce package -o rescript-vscode-${{ steps.vars.outputs.sha_short }}.vsix
213
213
214
214
- name : Package Extension pre-release version
215
215
if : github.ref == 'refs/heads/master'
216
- run : npx vsce package -o rescript-vscode-latest-master.vsix ${{ steps.increment_pre_release.outputs.new_version }} --no-git-tag-version
216
+ run : yarn dlx vsce package -o rescript-vscode-latest-master.vsix ${{ steps.increment_pre_release.outputs.new_version }} --no-git-tag-version
217
217
218
218
- name : Package Extension release version
219
219
if : startsWith(github.ref, 'refs/tags/')
220
- run : npx vsce package -o rescript-vscode-${{ steps.tag_name.outputs.tag }}.vsix ${{ steps.tag_name.outputs.tag }} --no-git-tag-version
220
+ run : yarn dlx vsce package -o rescript-vscode-${{ steps.tag_name.outputs.tag }}.vsix ${{ steps.tag_name.outputs.tag }} --no-git-tag-version
221
221
222
222
- uses : actions/upload-artifact@v4
223
223
if : github.ref != 'refs/heads/master'
@@ -273,37 +273,37 @@ jobs:
273
273
274
274
- name : Publish extension as pre-release
275
275
if : github.ref == 'refs/heads/master' && !startsWith(github.event.head_commit.message, 'publish tools')
276
- run : npx vsce publish --pat ${{ secrets.MARKETPLACE_TOKEN }} --pre-release ${{ steps.increment_pre_release.outputs.new_version }} --no-git-tag-version
276
+ run : yarn dlx vsce publish --pat ${{ secrets.MARKETPLACE_TOKEN }} --pre-release ${{ steps.increment_pre_release.outputs.new_version }} --no-git-tag-version
277
277
278
278
- name : Publish extension as release
279
279
if : startsWith(github.ref, 'refs/tags/')
280
- run : npx vsce publish --pat ${{ secrets.MARKETPLACE_TOKEN }} ${{ steps.tag_name.outputs.tag }} --no-git-tag-version
280
+ run : yarn dlx vsce publish --pat ${{ secrets.MARKETPLACE_TOKEN }} ${{ steps.tag_name.outputs.tag }} --no-git-tag-version
281
281
282
282
- name : Publish LSP as pre-release to NPM
283
283
if : github.ref == 'refs/heads/master'
284
284
working-directory : server
285
285
run : |
286
286
npm version preminor --preid next-$(git rev-parse --short HEAD)
287
- npm publish --access public --tag next
287
+ yarn publish --access public --tag next
288
288
env :
289
289
NODE_AUTH_TOKEN : ${{ secrets.NPM_TOKEN }}
290
290
291
291
- name : Publish LSP to NPM
292
292
if : startsWith(github.ref, 'refs/tags/')
293
293
working-directory : server
294
- run : npm publish --access public
294
+ run : yarn publish --access public
295
295
env :
296
296
NODE_AUTH_TOKEN : ${{ secrets.NPM_TOKEN }}
297
297
298
298
- name : Build @rescript/tools package
299
299
working-directory : tools
300
300
run : |
301
- npm ci
302
- npm run build
301
+ yarn install
302
+ yarn build
303
303
304
304
- name : Publish @rescript/tools package
305
305
if : ${{ startsWith(github.event.head_commit.message, 'publish tools') && (github.ref == 'refs/heads/master') }}
306
306
working-directory : tools
307
- run : npm publish --access public
307
+ run : yarn publish --access public
308
308
env :
309
309
NODE_AUTH_TOKEN : ${{ secrets.NPM_TOKEN }}
0 commit comments