Skip to content

Commit 59a8cf0

Browse files
authored
create tolk release github action (#1490)
* add create-tolk-release.yml * adjust create-tolk-release for old workflows * use custom tag * use old names * use old names
1 parent 1b7c46f commit 59a8cf0

File tree

2 files changed

+144
-0
lines changed

2 files changed

+144
-0
lines changed

.github/workflows/create-release.yml

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ jobs:
1717
workflow: ton-x86-64-linux.yml
1818
path: artifacts
1919
workflow_conclusion: success
20+
branch: master
2021
skip_unpack: true
2122

2223
- name: Download and unzip Linux x86-64 artifacts
@@ -25,6 +26,7 @@ jobs:
2526
workflow: ton-x86-64-linux.yml
2627
path: artifacts
2728
workflow_conclusion: success
29+
branch: master
2830
skip_unpack: false
2931

3032
- name: Download Mac x86-64 artifacts
@@ -33,6 +35,7 @@ jobs:
3335
workflow: ton-x86-64-macos.yml
3436
path: artifacts
3537
workflow_conclusion: success
38+
branch: master
3639
skip_unpack: true
3740

3841
- name: Download Mac arm64 artifacts
@@ -41,6 +44,7 @@ jobs:
4144
workflow: ton-arm64-macos.yml
4245
path: artifacts
4346
workflow_conclusion: success
47+
branch: master
4448
skip_unpack: true
4549

4650
- name: Download and unzip Mac x86-64 artifacts
@@ -49,6 +53,7 @@ jobs:
4953
workflow: ton-x86-64-macos.yml
5054
path: artifacts
5155
workflow_conclusion: success
56+
branch: master
5257
skip_unpack: false
5358

5459
- name: Download and unzip arm64 artifacts
@@ -57,6 +62,7 @@ jobs:
5762
workflow: ton-arm64-macos.yml
5863
path: artifacts
5964
workflow_conclusion: success
65+
branch: master
6066
skip_unpack: false
6167

6268
- name: Download Windows artifacts
@@ -65,6 +71,7 @@ jobs:
6571
workflow: ton-x86-64-windows.yml
6672
path: artifacts
6773
workflow_conclusion: success
74+
branch: master
6875
skip_unpack: true
6976

7077
- name: Download and unzip Windows artifacts
@@ -73,6 +80,7 @@ jobs:
7380
workflow: ton-x86-64-windows.yml
7481
path: artifacts
7582
workflow_conclusion: success
83+
branch: master
7684
skip_unpack: false
7785

7886
- name: Download WASM artifacts
@@ -81,6 +89,7 @@ jobs:
8189
workflow: build-ton-wasm-emscripten.yml
8290
path: artifacts
8391
workflow_conclusion: success
92+
branch: master
8493
skip_unpack: true
8594

8695
- name: Download Android Tonlib artifacts
@@ -89,6 +98,7 @@ jobs:
8998
workflow: build-ton-linux-android-tonlib.yml
9099
path: artifacts
91100
workflow_conclusion: success
101+
branch: master
92102
skip_unpack: true
93103

94104
- name: Show all artifacts
Lines changed: 134 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,134 @@
1+
name: Create tolk release
2+
3+
on:
4+
workflow_dispatch:
5+
inputs:
6+
tag:
7+
description: 'tolk release and tag name'
8+
required: true
9+
10+
permissions: write-all
11+
12+
jobs:
13+
create-release:
14+
runs-on: ubuntu-22.04
15+
16+
steps:
17+
- uses: actions/checkout@v3
18+
19+
- name: Download and unzip Linux x86-64 artifacts
20+
uses: dawidd6/action-download-artifact@v6
21+
with:
22+
workflow: ton-x86-64-linux.yml
23+
path: artifacts
24+
workflow_conclusion: success
25+
branch: master
26+
skip_unpack: false
27+
28+
- name: Download and unzip Mac x86-64 artifacts
29+
uses: dawidd6/action-download-artifact@v6
30+
with:
31+
workflow: ton-x86-64-macos.yml
32+
path: artifacts
33+
workflow_conclusion: success
34+
branch: master
35+
skip_unpack: false
36+
37+
- name: Download and unzip arm64 artifacts
38+
uses: dawidd6/action-download-artifact@v6
39+
with:
40+
workflow: ton-arm64-macos.yml
41+
path: artifacts
42+
workflow_conclusion: success
43+
branch: master
44+
skip_unpack: false
45+
46+
- name: Download and unzip Windows artifacts
47+
uses: dawidd6/action-download-artifact@v6
48+
with:
49+
workflow: ton-x86-64-windows.yml
50+
path: artifacts
51+
workflow_conclusion: success
52+
branch: master
53+
skip_unpack: false
54+
55+
- name: Download WASM artifacts
56+
uses: dawidd6/action-download-artifact@v6
57+
with:
58+
workflow: build-ton-wasm-emscripten.yml
59+
path: artifacts
60+
workflow_conclusion: success
61+
branch: master
62+
skip_unpack: true
63+
64+
- name: Show all artifacts
65+
run: |
66+
tree artifacts
67+
68+
69+
# create release
70+
- name: Get registration token
71+
id: getRegToken
72+
run: |
73+
curl -X POST -H \"Accept: application/vnd.github+json\" -H 'Authorization: token ${{ secrets.GITHUB_TOKEN }}' https://api.github.com/repos/ton-blockchain/ton/actions/runners/registration-token
74+
75+
- name: Create release
76+
id: create_release
77+
uses: actions/create-release@v1
78+
env:
79+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
80+
with:
81+
tag_name: ${{ inputs.tag }}
82+
release_name: ${{ inputs.tag }}
83+
draft: false
84+
prerelease: false
85+
86+
# upload
87+
88+
# win
89+
90+
- name: Upload Windows 2019 single artifact - tolk
91+
uses: svenstaro/upload-release-action@v2
92+
with:
93+
repo_token: ${{ secrets.GITHUB_TOKEN }}
94+
file: artifacts/ton-win-binaries/tolk.exe
95+
asset_name: tolk.exe
96+
tag: ${{ inputs.tag }}
97+
98+
# mac x86-64
99+
100+
- name: Upload Mac x86-64 single artifact - tolk
101+
uses: svenstaro/upload-release-action@v2
102+
with:
103+
repo_token: ${{ secrets.GITHUB_TOKEN }}
104+
file: artifacts/ton-x86_64-macos-binaries/tolk
105+
asset_name: tolk-mac-x86-64
106+
tag: ${{ inputs.tag }}
107+
108+
# mac arm64
109+
110+
- name: Upload Mac arm64 single artifact - tolk
111+
uses: svenstaro/upload-release-action@v2
112+
with:
113+
repo_token: ${{ secrets.GITHUB_TOKEN }}
114+
file: artifacts/ton-arm64-macos-binaries/tolk
115+
asset_name: tolk-mac-arm64
116+
tag: ${{ inputs.tag }}
117+
118+
# linux x86-64
119+
120+
- name: Upload Linux x86-64 single artifact - tolk
121+
uses: svenstaro/upload-release-action@v2
122+
with:
123+
repo_token: ${{ secrets.GITHUB_TOKEN }}
124+
file: artifacts/ton-x86_64-linux-binaries/tolk
125+
asset_name: tolk-linux-x86_64
126+
tag: ${{ inputs.tag }}
127+
128+
- name: Upload WASM artifacts
129+
uses: svenstaro/upload-release-action@v2
130+
with:
131+
repo_token: ${{ secrets.GITHUB_TOKEN }}
132+
file: artifacts/ton-wasm-binaries.zip
133+
asset_name: ton-wasm.zip
134+
tag: ${{ inputs.tag }}

0 commit comments

Comments
 (0)