-
Notifications
You must be signed in to change notification settings - Fork 0
164 lines (138 loc) Β· 3.92 KB
/
release.yaml
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
name: release
on:
push:
tags:
- "v*.*.*"
jobs:
build-windows-artifacts:
name: build-windows-${{ matrix.platform }}
runs-on: windows-2022
strategy:
fail-fast: false
matrix:
platform: [ win32, win64 ]
include:
- platform: win32
arch: x86
- platform: win64
arch: x64
defaults:
run:
shell: bash
steps:
- uses: actions/checkout@v4
- name: Install UPX
uses: crazy-max/ghaction-upx@v3
with:
install-only: true
- name: Set up Python 3.12
uses: actions/setup-python@v5
with:
python-version: 3.12
architecture: ${{ matrix.arch }}
- name: Install poetry and dependencies
uses: ./.github/actions/bootstrap-poetry
with:
os: windows
- name: Build release
run: poetry run python scripts/build.py --os windows
- name: Rename artifact
run: ./scripts/rename-release-file.sh windows
- name: Upload artifact
uses: actions/upload-artifact@v4
with:
name: windows-assets-${{ matrix.platform }}
path: ${{ github.workspace }}/dist/doggo-*.exe
retention-days: 2
build-macos-artifacts:
name: build-macos-${{ matrix.platform }}
runs-on: ${{ matrix.image }}
strategy:
fail-fast: false
matrix:
platform: [ Intel, AppleSilicon ]
include:
- platform: Intel
image: macos-13
- platform: AppleSilicon
image: macos-14
defaults:
run:
shell: bash
steps:
- uses: actions/checkout@v4
- name: Set up Python 3.12
uses: actions/setup-python@v5
with:
python-version: 3.12
- name: Install poetry and dependencies
uses: ./.github/actions/bootstrap-poetry
with:
os: macos
- name: Build release
run: poetry run python scripts/build.py --os macos
- name: Install create-dmg
run: brew install create-dmg
- name: Create dmg file
run: ./scripts/create-dmg.sh
- name: Rename artifact
run: ./scripts/rename-release-file.sh macos
- name: Upload artifact
uses: actions/upload-artifact@v4
with:
name: macos-assets-${{ matrix.platform }}
path: ${{ github.workspace }}/dist/doggo-*.dmg
retention-days: 2
build-linux-artifacts:
name: build-linux-generic
runs-on: ubuntu-20.04
defaults:
run:
shell: bash
steps:
- uses: actions/checkout@v4
- name: Install UPX
uses: crazy-max/ghaction-upx@v3
with:
install-only: true
- name: Set up Python 3.12
uses: actions/setup-python@v5
with:
python-version: 3.12
- name: Install poetry and dependencies
uses: ./.github/actions/bootstrap-poetry
with:
os: linux
- name: Build release
run: poetry run python scripts/build.py --os linux
- name: Install appimage-builder
run: pip install appimage-builder
- name: Create AppImage file
run: ./scripts/create-appimage.sh
- name: Rename artifact
run: ./scripts/rename-release-file.sh linux
- name: Upload artifact
uses: actions/upload-artifact@v4
with:
name: linux-assets
path: ${{ github.workspace }}/dist/doggo-*.AppImage
retention-days: 2
publish-release:
needs: [ build-windows-artifacts, build-macos-artifacts, build-linux-artifacts ]
runs-on: ubuntu-latest
environment: publish-release
steps:
- uses: actions/checkout@v4
- name: Download artifacts
uses: actions/download-artifact@v4
- name: Publish release
uses: softprops/action-gh-release@v2
with:
name: ${{ github.ref_name }}
tag_name: ${{ github.ref_name }}
draft: true
files: |
windows-assets-*/doggo-*.exe
macos-assets-*/doggo-*.dmg
linux-assets/doggo-*.AppImage
LICENSE