-
Notifications
You must be signed in to change notification settings - Fork 0
194 lines (191 loc) · 6.43 KB
/
build.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
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
190
191
192
193
194
name: Build
on:
workflow_run:
workflows: ["Run Tests"]
branches: [main]
types:
- completed
env:
CARGO_TERM_COLOR: always
jobs:
build_linux:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Get version
run: |
export version=$(python3 tools/prep_diz.py "file_id.diz")
echo "VERSION=$version" >> $GITHUB_ENV
echo "Version: $version"
- name: Build
id: build
run: |
cargo build --release
echo "Copy $DEB to icy_board.deb"
mkdir bin
mv target/release/icy_board bin
mv target/release/icbsetup bin
mv target/release/icbmailer bin
mv target/release/icbsysmgr bin
mv target/release/mkicbmnu bin
mv target/release/mkicbtxt bin
mv target/release/pplc bin
mv target/release/ppld bin
mv target/release/ppl-language-server bin
- name: 'Upload zip'
uses: actions/upload-artifact@v4
with:
name: icy_board_linux_${{ env.VERSION }}
path: |
bin/icy_board
bin/icbsetup
bin/icbmailer
bin/icbsysmgr
bin/mkicbmnu
bin/mkicbtxt
bin/pplc
bin/pppld
bin/ppl-language-server
file_id.diz
INSTALL.txt
build_windows:
runs-on: windows-latest
steps:
- uses: actions/checkout@v4
- name: Get version
run: |
$VERSION=$(python tools\prep_diz.py "file_id.diz")
Add-Content -Path $env:GITHUB_ENV -Value "VERSION=$VERSION"
echo "Version $VERSION"
- name: Build
id: build
run: |
cargo build --release
echo "Copy $DEB to icy_board.deb"
mkdir bin
move target/release/icy_board.exe bin
move target/release/icbsetup.exe bin
move target/release/icbmailer.exe bin
move target/release/icbsysmgr.exe bin
move target/release/mkicbmnu.exe bin
move target/release/mkicbtxt.exe bin
move target/release/pplc.exe bin
move target/release/ppld.exe bin
move target/release/ppl-language-server.exe bin
- name: 'Upload zip'
uses: actions/upload-artifact@v4
with:
name: icy_board_windows_${{ env.VERSION }}
path: |
bin/icy_board.exe
bin/icbsetup.exe
bin/icbmailer.exe
bin/icbsysmgr.exe
bin/mkicbmnu.exe
bin/mkicbtxt.exe
bin/pplc.exe
bin/pppld.exe
bin/ppl-language-server.exe
file_id.diz
INSTALL.txt
build_mac:
runs-on: macos-13
steps:
- uses: actions/checkout@v4
- name: Get version
run: |
export version=$(python3 tools/prep_diz.py "file_id.diz")
echo "VERSION=$version" >> $GITHUB_ENV
echo "Version: $version"
- name: Install rust compilation targets
run: |
rustup target add aarch64-apple-darwin
rustup target add x86_64-apple-darwin
- name: Build
id: build
run: |
cargo build --release --target aarch64-apple-darwin
cargo build --release --target x86_64-apple-darwin
echo "Copy $DEB to icy_board.deb"
mkdir -p aarch64-apple-darwin/bin
mv target/aarch64-apple-darwin/release/icy_board aarch64-apple-darwin/bin
mv target/aarch64-apple-darwin/release/icbsetup aarch64-apple-darwin/bin
mv target/aarch64-apple-darwin/release/icbmailer aarch64-apple-darwin/bin
mv target/aarch64-apple-darwin/release/icbsysmgr aarch64-apple-darwin/bin
mv target/aarch64-apple-darwin/release/mkicbmnu aarch64-apple-darwin/bin
mv target/aarch64-apple-darwin/release/mkicbtxt aarch64-apple-darwin/bin
mv target/aarch64-apple-darwin/release/pplc aarch64-apple-darwin/bin
mv target/aarch64-apple-darwin/release/ppld aarch64-apple-darwin/bin
mv target/aarch64-apple-darwin/release/ppl-language-server aarch64-apple-darwin/bin
mkdir -p x86_64-apple-darwin/bin
mv target/x86_64-apple-darwin/release/icy_board x86_64-apple-darwin/bin
mv target/x86_64-apple-darwin/release/icbsetup x86_64-apple-darwin/bin
mv target/x86_64-apple-darwin/release/icbmailer x86_64-apple-darwin/bin
mv target/x86_64-apple-darwin/release/icbsysmgr x86_64-apple-darwin/bin
mv target/x86_64-apple-darwin/release/mkicbmnu x86_64-apple-darwin/bin
mv target/x86_64-apple-darwin/release/mkicbtxt x86_64-apple-darwin/bin
mv target/x86_64-apple-darwin/release/pplc x86_64-apple-darwin/bin
mv target/x86_64-apple-darwin/release/ppld x86_64-apple-darwin/bin
mv target/x86_64-apple-darwin/release/ppl-language-server x86_64-apple-darwin/bin
- name: 'Upload zip'
uses: actions/upload-artifact@v4
with:
name: icy_board_osx_aarch64-apple-darwin_${{ env.VERSION }}
path: |
aarch64-apple-darwin/bin/icy_board
aarch64-apple-darwin/bin/icbsetup
aarch64-apple-darwin/bin/icbmailer
aarch64-apple-darwin/bin/icbsysmgr
aarch64-apple-darwin/bin/mkicbmnu
aarch64-apple-darwin/bin/mkicbtxt
aarch64-apple-darwin/bin/pplc
aarch64-apple-darwin/bin/pppld
aarch64-apple-darwin/bin/ppl-language-server
file_id.diz
INSTALL.txt
- name: 'Upload zip'
uses: actions/upload-artifact@v4
with:
name: icy_board_osx_x86_64-apple-darwin_${{ env.VERSION }}
path: |
x86_64-apple-darwin/bin/icy_board
x86_64-apple-darwin/bin/icbsetup
x86_64-apple-darwin/bin/icbmailer
x86_64-apple-darwin/bin/icbsysmgr
x86_64-apple-darwin/bin/mkicbmnu
x86_64-apple-darwin/bin/mkicbtxt
x86_64-apple-darwin/bin/pplc
x86_64-apple-darwin/bin/pppld
x86_64-apple-darwin/bin/ppl-language-server
file_id.diz
INSTALL.txt
build_vs_extension:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v2
name: Install pnpm
with:
version: 10
run_install: false
- name: Get version
run: |
export version=$(python3 ./tools/get_version.py)
echo "Version: $VERSION"
echo "VERSION=$version" >> $GITHUB_ENV
- name: Install required libraries
run: |
cd crates/ppl-lsp
pnpm i
- name: Build
id: build
run: |
cd crates/ppl-lsp
tsc -b
npm run compile
pnpm run package
- name: 'Upload zip'
uses: actions/upload-artifact@v4
with:
name: ppl-language-server-${{ env.VERSION }}.vsix
path: crates/ppl-lsp/ppl-language-server-${{ env.VERSION }}.vsix