-
Notifications
You must be signed in to change notification settings - Fork 0
171 lines (147 loc) · 3.93 KB
/
ci.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
name: nightly
on:
push:
branches: [ master ]
pull_request:
jobs:
linux-x86_64:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Build
run: make all BUILD_TYPE=Release
- name: Upload Artifacts
uses: actions/upload-artifact@v2
with:
name: linux-x86_64
path: ./build/
if-no-files-found: error
mac-x86_64:
runs-on: macos-11
steps:
- uses: actions/checkout@v4
- name: Build
run: make all BUILD_TYPE=Release
- name: Upload Artifacts
uses: actions/upload-artifact@v2
with:
name: mac-x86_64
path: ./build/
if-no-files-found: error
netbsd-x86_64:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Run NetBSD VM & Build
id: test
uses: vmactions/netbsd-vm@v1
with:
usesh: true
prepare: |
/usr/sbin/pkg_add gmake
run: |
gmake all BUILD_TYPE=Release CC=gcc
- name: Upload Artifacts
uses: actions/upload-artifact@v2
with:
name: netbsd-x86_64
path: ./build/
if-no-files-found: error
freebsd-x86_64:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Run FreeBSD VM & Build
id: termrec
uses: vmactions/freebsd-vm@v1
with:
usesh: true
prepare: |
pkg install -y gmake
run: |
gmake all BUILD_TYPE=Release CC=clang
- name: Upload Artifacts
uses: actions/upload-artifact@v2
with:
name: freebsd-x86_64
path: ./build/
if-no-files-found: error
openbsd-x86_64:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
with:
submodules: recursive
- name: Run OpenBSD VM & Build
id: termrec
uses: vmactions/openbsd-vm@v1
with:
usesh: true
prepare: |
pkg_add gmake
run: |
gmake all BUILD_TYPE=Release CC=clang
- name: Upload Artifacts
uses: actions/upload-artifact@v2
with:
name: openbsd-x86_64
path: ./build/
if-no-files-found: error
update-ci-release:
needs: [linux-x86_64, mac-x86_64, netbsd-x86_64, freebsd-x86_64, openbsd-x86_64]
permissions:
contents: write
if: |
github.event_name == 'push' ||
github.event.pull_request.merged == true
runs-on: ubuntu-latest
steps:
- uses: dev-drprasad/[email protected]
with:
tag_name: nightly
delete_release: true
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- uses: actions/download-artifact@v3
with:
name: linux-x86_64
path: ./linux-x86_64/
- uses: actions/download-artifact@v3
with:
name: openbsd-x86_64
path: ./openbsd-x86_64/
- uses: actions/download-artifact@v3
with:
name: freebsd-x86_64
path: ./freebsd-x86_64/
- uses: actions/download-artifact@v3
with:
name: netbsd-x86_64
path: ./netbsd-x86_64/
- uses: actions/download-artifact@v3
with:
name: mac-x86_64
path: ./mac-x86_64/
- name: Rename
run: |
mv ./linux-x86_64/termrec ./termrec-linux-x86_64
mv ./freebsd-x86_64/termrec ./termrec-freebsd-x86_64
mv ./openbsd-x86_64/termrec ./termrec-openbsd-x86_64
mv ./netbsd-x86_64/termrec ./termrec-netbsd-x86_64
mv ./mac-x86_64/termrec ./termrec-mac-x86_64
- uses: ncipollo/release-action@v1
with:
name: "Termrec dev build"
body: "this release is not for daily use."
tag: "nightly"
commit: "master"
prerelease: true
allowUpdates: true
generateReleaseNotes: true
artifactErrorsFailBuild: true
artifacts: |
./termrec-linux-x86_64
./termrec-freebsd-x86_64
./termrec-openbsd-x86_64
./termrec-netbsd-x86_64
./termrec-mac-x86_64