Skip to content

Commit b0cd8aa

Browse files
authored
Update build.yml
1 parent 7c41782 commit b0cd8aa

File tree

1 file changed

+11
-5
lines changed

1 file changed

+11
-5
lines changed

.github/workflows/build.yml

Lines changed: 11 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,8 @@ jobs:
3838
echo "::set-output name=version::$VERSION"
3939
echo "SPP_CLI_VERSION=$VERSION" >> $GITHUB_ENV
4040
echo "SPP_RELEASE_VERSION=${VERSION/-SNAPSHOT/}" >> $GITHUB_ENV
41+
SPP_RELEASE_VERSION=${VERSION/-SNAPSHOT/}
42+
echo "::set-output name=release_version::$SPP_RELEASE_VERSION"
4143
4244
- name: Build native spp-cli (Release)
4345
if: github.ref == 'refs/heads/master'
@@ -89,6 +91,8 @@ jobs:
8991
echo "::set-output name=version::$VERSION"
9092
echo "SPP_CLI_VERSION=$VERSION" >> $GITHUB_ENV
9193
echo "SPP_RELEASE_VERSION=${VERSION/-SNAPSHOT/}" >> $GITHUB_ENV
94+
SPP_RELEASE_VERSION=${VERSION/-SNAPSHOT/}
95+
echo "::set-output name=release_version::$SPP_RELEASE_VERSION"
9296
9397
- name: Build native spp-cli.exe (Release)
9498
if: github.ref == 'refs/heads/master'
@@ -146,6 +150,8 @@ jobs:
146150
echo "::set-output name=version::$VERSION"
147151
echo "SPP_CLI_VERSION=$VERSION" >> $GITHUB_ENV
148152
echo "SPP_RELEASE_VERSION=${VERSION/-SNAPSHOT/}" >> $GITHUB_ENV
153+
SPP_RELEASE_VERSION=${VERSION/-SNAPSHOT/}
154+
echo "::set-output name=release_version::$SPP_RELEASE_VERSION"
149155
150156
- name: Build native spp-cli (Release)
151157
if: github.ref == 'refs/heads/master'
@@ -257,8 +263,8 @@ jobs:
257263
env:
258264
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
259265
with:
260-
tag_name: ${{ needs.buildOnLinux.outputs.version }}
261-
release_name: v${{ needs.buildOnLinux.outputs.version }}
266+
tag_name: ${{ needs.buildOnLinux.outputs.release_version }}
267+
release_name: v${{ needs.buildOnLinux.outputs.release_version }}
262268
body: ${{ needs.build.outputs.changelog }}
263269
draft: true
264270

@@ -274,7 +280,7 @@ jobs:
274280
with:
275281
upload_url: ${{ steps.createDraft.outputs.upload_url }}
276282
asset_path: ./spp-cli-macOS.zip
277-
asset_name: spp-cli-${{ needs.buildOnLinux.outputs.version }}-macOS.zip
283+
asset_name: spp-cli-${{ needs.buildOnLinux.outputs.release_version }}-macOS.zip
278284
asset_content_type: application/zip
279285

280286
- name: Download spp-cli-win64 artifact
@@ -289,7 +295,7 @@ jobs:
289295
with:
290296
upload_url: ${{ steps.createDraft.outputs.upload_url }}
291297
asset_path: ./spp-cli-win64.zip
292-
asset_name: spp-cli-${{ needs.buildOnLinux.outputs.version }}-win64.zip
298+
asset_name: spp-cli-${{ needs.buildOnLinux.outputs.release_version }}-win64.zip
293299
asset_content_type: application/zip
294300

295301
- name: Download spp-cli-linux64 artifact
@@ -304,5 +310,5 @@ jobs:
304310
with:
305311
upload_url: ${{ steps.createDraft.outputs.upload_url }}
306312
asset_path: ./spp-cli-linux64.zip
307-
asset_name: spp-cli-${{ needs.buildOnLinux.outputs.version }}-linux64.zip
313+
asset_name: spp-cli-${{ needs.buildOnLinux.outputs.release_version }}-linux64.zip
308314
asset_content_type: application/zip

0 commit comments

Comments
 (0)