-
Notifications
You must be signed in to change notification settings - Fork 0
135 lines (127 loc) · 3.82 KB
/
Copy pathrelease.yml
File metadata and controls
135 lines (127 loc) · 3.82 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
name: Test and build every platform
on:
workflow_dispatch:
push:
tags: ["v*"]
permissions:
contents: write
concurrency:
group: redex-release-${{ github.ref }}
cancel-in-progress: false
jobs:
test:
runs-on: ubuntu-latest
timeout-minutes: 25
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 22
cache: npm
- run: npm ci
- run: npm test
- run: npm run check
- run: npm run build
windows:
needs: test
runs-on: windows-latest
timeout-minutes: 50
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 22
cache: npm
- run: npm ci
- name: Include both Windows Copilot runtimes
shell: pwsh
run: |
$version = node -p "require('@github/copilot/package.json').version"
npm install --force --no-save "@github/copilot-win32-x64@$version" "@github/copilot-win32-arm64@$version"
- name: Build actual NSIS installers and portable apps
shell: pwsh
run: npx electron-builder --win nsis portable --x64 --arm64 --publish never
env:
CSC_LINK: ${{ secrets.WINDOWS_CSC_LINK }}
CSC_KEY_PASSWORD: ${{ secrets.WINDOWS_CSC_KEY_PASSWORD }}
- uses: actions/upload-artifact@v4
with:
name: RedEXCompile-Windows-${{ github.ref_name }}
path: |
release/*.exe
release/*.yml
release/*.blockmap
if-no-files-found: error
macos:
needs: test
runs-on: macos-14
timeout-minutes: 60
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 22
cache: npm
- run: npm ci
- name: Include Intel and Apple Silicon Copilot runtimes
run: |
version=$(node -p "require('@github/copilot/package.json').version")
npm install --force --no-save "@github/copilot-darwin-x64@$version" "@github/copilot-darwin-arm64@$version"
- name: Build Intel and Apple Silicon packages
run: npx electron-builder --mac dmg zip --x64 --arm64 --publish never
env:
CSC_LINK: ${{ secrets.MACOS_CSC_LINK }}
CSC_KEY_PASSWORD: ${{ secrets.MACOS_CSC_KEY_PASSWORD }}
- uses: actions/upload-artifact@v4
with:
name: RedEXCompile-macOS-${{ github.ref_name }}
path: |
release/*.dmg
release/*.zip
release/*.yml
release/*.blockmap
if-no-files-found: error
linux:
needs: test
runs-on: ubuntu-latest
timeout-minutes: 45
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 22
cache: npm
- run: npm ci
- name: Build AppImage and Debian package
run: npx electron-builder --linux AppImage deb --x64 --publish never
- uses: actions/upload-artifact@v4
with:
name: RedEXCompile-Linux-${{ github.ref_name }}
path: |
release/*.AppImage
release/*.deb
release/*.yml
release/*.blockmap
if-no-files-found: error
release:
if: startsWith(github.ref, 'refs/tags/')
needs: [windows, macos, linux]
runs-on: ubuntu-latest
steps:
- uses: actions/download-artifact@v4
with:
pattern: RedEXCompile-*
path: artifacts
merge-multiple: true
- uses: softprops/action-gh-release@v2
with:
generate_release_notes: true
fail_on_unmatched_files: true
files: |
artifacts/*.exe
artifacts/*.dmg
artifacts/*.zip
artifacts/*.AppImage
artifacts/*.deb
artifacts/*.yml
artifacts/*.blockmap