forked from PoC-Consortium/burstcoin
-
-
Notifications
You must be signed in to change notification settings - Fork 78
92 lines (87 loc) · 4.26 KB
/
release.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
# This workflow will build a Java project with Maven
# For more information see: https://help.github.com/actions/language-and-framework-guides/building-and-testing-java-with-maven
name: Draft release for Signum Node
on:
workflow_dispatch:
push:
tags:
- 'v*'
jobs:
build:
name: Create Release Draft
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Update Wallets
run: |
cd ./ci
./updatePhoenix.sh
./updateClassic.sh
- name: Setup NodeJS
uses: actions/setup-node@v4
with:
node-version: 16
- name: Set up JDK 11
uses: actions/setup-java@v4
with:
distribution: 'zulu'
java-version: '11'
- name: Build All
run: ./gradlew release
- name: Create Release
id: create_release
uses: actions/[email protected]
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: ${{ github.ref }}
release_name: Signum Node ${{ github.ref }}
draft: true
prerelease: false
- name: Get the version
id: get_version
run: echo ::set-output name=VERSION::${GITHUB_REF/refs\/tags\//}
- name: Get the version number
id: get_version_number
run: echo ::set-output name=VERSION::${GITHUB_REF/refs\/tags\//}
- name: Upload Release Asset - Zip
id: upload-release-asset-zip
uses: actions/[email protected]
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.create_release.outputs.upload_url }} # This pulls from the CREATE RELEASE step above, referencing it's ID to get its outputs object, which include a `upload_url`. See this blog post for more info: https://jasonet.co/posts/new-features-of-github-actions/#passing-data-to-future-steps
asset_path: ./build/distributions/signum-node.zip
asset_name: signum-node-${{ steps.get_version.outputs.VERSION }}.zip
asset_content_type: application/zip
- name: Upload Release Asset - Zip checksum
id: upload-release-asset-zip-checksum
uses: actions/[email protected]
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.create_release.outputs.upload_url }} # This pulls from the CREATE RELEASE step above, referencing it's ID to get its outputs object, which include a `upload_url`. See this blog post for more info: https://jasonet.co/posts/new-features-of-github-actions/#passing-data-to-future-steps
asset_path: ./build/checksums/signum-node.zip.sha256
asset_name: signum-node-${{ steps.get_version.outputs.VERSION }}.zip.sha256
asset_content_type: text/plain
- name: Upload Release Asset - WindowsZip
id: upload-release-asset-windows-zip
uses: actions/[email protected]
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.create_release.outputs.upload_url }} # This pulls from the CREATE RELEASE step above, referencing it's ID to get its outputs object, which include a `upload_url`. See this blog post for more info: https://jasonet.co/posts/new-features-of-github-actions/#passing-data-to-future-steps
asset_path: ./build/distributions/signum-node-win_x64.zip
asset_name: signum-node-${{ steps.get_version.outputs.VERSION }}-win_x64.zip
asset_content_type: application/zip
- name: Upload Release Asset - WindowsZip checksum
id: upload-release-asset-windows-zip-checksum
uses: actions/[email protected]
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.create_release.outputs.upload_url }} # This pulls from the CREATE RELEASE step above, referencing it's ID to get its outputs object, which include a `upload_url`. See this blog post for more info: https://jasonet.co/posts/new-features-of-github-actions/#passing-data-to-future-steps
asset_path: ./build/checksums/signum-node-win_x64.zip.sha256
asset_name: signum-node-${{ steps.get_version.outputs.VERSION }}-win_x64.zip.sha256
asset_content_type: text/plain