-
-
Notifications
You must be signed in to change notification settings - Fork 32
189 lines (182 loc) · 6.21 KB
/
flow-release.yml
File metadata and controls
189 lines (182 loc) · 6.21 KB
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
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
name: HyperFlow Release
on:
push:
tags:
- "hyper-flow-v[0-9]+.[0-9]+.[0-9]+"
jobs:
publish_on_win:
name: Build HyperFlow on Windows
runs-on: windows-latest
needs: prepare-environment
# Tests timeout after 40 minutes
timeout-minutes: 40
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: "20.19.3"
cache: "yarn"
cache-dependency-path: yarn.lock
- name: Get yarn cache directory path
id: yarn-cache-dir-path
run: |
echo "dir=$(yarn cache dir)" >> $GITHUB_OUTPUT
echo "version=$(yarn -v)" >> $GITHUB_OUTPUT
- name: Restore node_modules
uses: actions/cache/restore@v4
id: cache-node-modules
with:
path: |
**/node_modules
**/.eslintcache
${{ steps.yarn-cache-dir-path.outputs.dir }}
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
${{ runner.os }}-yarn-
- name: Install node_modules on cache miss
if: steps.cache-node-modules.outputs.cache-hit != 'true'
run: yarn install --network-timeout 1000000
- name: Cache node_modules
if: steps.cache-node-modules.outputs.cache-hit != 'true'
uses: actions/cache/save@v4
with:
path: |
${{ steps.yarn-cache-dir-path.outputs.dir }}
'**/node_modules'
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
${{ runner.os }}-yarn-
- name: Build
run: yarn build
- name: Release
run: yarn nx run hyper-flow:publish:app
env:
APPLE_ID: ${{ secrets.APPLE_ID }}
APPLE_PASSWORD: ${{ secrets.APPLE_PASSWORD }}
APPLE_TEAM_ID: ${{ secrets.APPLE_TEAM_ID }}
SIGN_ID: ${{ secrets.SIGN_ID }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
publish_on_linux:
name: Publish HyperFlow on Linux
runs-on: ubuntu-latest
needs: prepare-environment
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: "20.19.3"
cache: "yarn"
cache-dependency-path: yarn.lock
- name: Get yarn cache directory path
id: yarn-cache-dir-path
run: |
echo "dir=$(yarn cache dir)" >> $GITHUB_OUTPUT
echo "version=$(yarn -v)" >> $GITHUB_OUTPUT
- name: Restore node_modules
uses: actions/cache/restore@v4
id: cache-node-modules
with:
path: |
**/node_modules
**/.eslintcache
${{ steps.yarn-cache-dir-path.outputs.dir }}
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
${{ runner.os }}-yarn-
- name: Install node_modules on cache miss
if: steps.cache-node-modules.outputs.cache-hit != 'true'
run: yarn install
- name: Cache node_modules
if: steps.cache-node-modules.outputs.cache-hit != 'true'
uses: actions/cache/save@v4
with:
path: |
${{ steps.yarn-cache-dir-path.outputs.dir }}
'**/node_modules'
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
${{ runner.os }}-yarn-
- name: Build
run: yarn build
- name: Release
run: yarn nx run hyper-flow:publish:app
env:
APPLE_ID: ${{ secrets.APPLE_ID }}
APPLE_PASSWORD: ${{ secrets.APPLE_PASSWORD }}
APPLE_TEAM_ID: ${{ secrets.APPLE_TEAM_ID }}
SIGN_ID: ${{ secrets.SIGN_ID }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
publish_on_mac:
name: Publish HyperFlow on Mac
runs-on: macos-latest
# Tests timeout after 40 minutes
timeout-minutes: 40
needs: prepare-environment
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: "20.19.3"
cache: "yarn"
cache-dependency-path: yarn.lock
- name: Install Python
uses: actions/setup-python@v4
with:
python-version: "3.11"
- name: Import codesign certs
uses: apple-actions/import-codesign-certs@v3
with:
p12-file-base64: ${{ secrets.APPSTORE_CERTIFICATES_FILE_BASE64 }}
p12-password: ${{ secrets.APPSTORE_CERTIFICATES_PASSWORD }}
- name: Get yarn cache directory path
id: yarn-cache-dir-path
run: |
echo "dir=$(yarn cache dir)" >> $GITHUB_OUTPUT
echo "version=$(yarn -v)" >> $GITHUB_OUTPUT
- name: Restore node_modules
uses: actions/cache/restore@v4
id: cache-node-modules
with:
path: |
**/node_modules
**/.eslintcache
${{ steps.yarn-cache-dir-path.outputs.dir }}
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
${{ runner.os }}-yarn-
- name: Install node_modules on cache miss
if: steps.cache-node-modules.outputs.cache-hit != 'true'
run: yarn install
- name: Install macos-alias
run: yarn add macos-alias@0.2.12 -W
- name: Rebuild native modules
run: |
npm install -g node-gyp
npm rebuild
yarn install --force
- name: Cache node_modules
if: steps.cache-node-modules.outputs.cache-hit != 'true'
uses: actions/cache/save@v4
with:
path: |
${{ steps.yarn-cache-dir-path.outputs.dir }}
'**/node_modules'
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
${{ runner.os }}-yarn-
- name: Build
run: yarn build
- name: Release
run: yarn nx run hyper-flow:publish:app
env:
APPLE_ID: ${{ secrets.APPLE_ID }}
APPLE_PASSWORD: ${{ secrets.APPLE_PASSWORD }}
APPLE_TEAM_ID: ${{ secrets.APPLE_TEAM_ID }}
SIGN_ID: ${{ secrets.SIGN_ID }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}