@@ -142,7 +142,7 @@ jobs:
142
142
shell : bash
143
143
- name : List packages
144
144
run :
145
- ls -R ./packages/cli ./packages/core-linux-* ./packages/core-macos-*
145
+ ls -lR ./packages/cli ./packages/core-linux-* ./packages/core-macos-*
146
146
./packages/core-windows-*
147
147
shell : bash
148
148
- name : Test binary
@@ -153,7 +153,7 @@ jobs:
153
153
154
154
publish :
155
155
if : ${{ github.event_name == 'workflow_dispatch' }}
156
- name : Publish
156
+ name : Publish cli/core packages
157
157
runs-on : ubuntu-latest
158
158
needs :
159
159
- test
@@ -181,25 +181,50 @@ jobs:
181
181
path : artifacts
182
182
- name : Sync artifact binaries
183
183
run : node ./scripts/release/syncArtifacts.mjs
184
- - name : Mark binaries as executable
185
- run : |
186
- chmod +x packages/core-linux-x64-gnu/moon
187
- chmod +x packages/core-macos-x64/moon
188
- chmod +x packages/core-windows-x64-msvc/moon.exe
189
184
- name : List binaries
190
- run : ls -lR artifacts
185
+ run : ls -lR ./ artifacts/release ./packages/core-*
191
186
shell : bash
192
187
- name : Publish npm packages
193
188
run : bash ./scripts/release/publishBinaryPackages.sh
194
189
shell : bash
195
190
env :
196
191
GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
197
192
NPM_TOKEN : ${{ secrets.NPM_TOKEN }}
198
- # TODO changelog
199
193
- uses : softprops/action-gh-release@v1
200
194
name : Create GitHub release
201
195
with :
202
196
fail_on_unmatched_files : true
203
197
files : artifacts/release/*
204
198
tag_name : ${{ env.NPM_TAG_NAME }}
205
199
prerelease : ${{ env.NPM_CHANNEL == 'next' }}
200
+
201
+ publish-npm :
202
+ if : ${{ github.event_name == 'workflow_dispatch' }}
203
+ name : Publish npm packages
204
+ runs-on : ubuntu-latest
205
+ env :
206
+ NPM_CHANNEL : latest
207
+ steps :
208
+ - uses : actions/checkout@v3
209
+ - uses : actions/setup-node@v3
210
+ with :
211
+ check-latest : true
212
+ node-version : 16
213
+ - uses : actions/cache@v3
214
+ name : Cache node modules
215
+ with :
216
+ path : |
217
+ ~/.yarn
218
+ .yarn/install-state.gz
219
+ key : ${{ runner.os }}-yarn-${{ hashFiles('yarn.lock') }}
220
+ restore-keys : ${{ runner.os }}-yarn-
221
+ - name : Install dependencies
222
+ run : yarn install --immutable
223
+ - name : Build packages
224
+ run : yarn run build
225
+ - name : Publish npm packages
226
+ run : bash ./scripts/release/publishPackages.sh
227
+ shell : bash
228
+ env :
229
+ GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
230
+ NPM_TOKEN : ${{ secrets.NPM_TOKEN }}
0 commit comments