-
Notifications
You must be signed in to change notification settings - Fork 4
72 lines (62 loc) · 2.1 KB
/
build_windows.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
name: Build Windows
on:
push:
branches:
- '*'
pull_request:
branches:
- '*'
workflow_dispatch:
jobs:
build:
name: Build packages
runs-on: windows-2019
steps:
- uses: actions/checkout@v3
- name: Set up Python 3.7
uses: actions/setup-python@v4
with:
python-version: "3.7"
# Not using the ANTs c++ backend on Windows, have to investigate how to execute the bash scripts.
# But have to download it due to the expected copying of the install folder...
- name: Download ANTs
uses: robinraju/release-downloader@main
with:
repository: "raidionics/Raidionics-dependencies"
latest: true
fileName: "ANTsX-v2.4.3_windows.zip"
out-file-path: "downloads"
- name: Extract ANTs
run: |
cd ${{github.workspace}}/downloads/
mkdir ${{github.workspace}}/ANTs
mkdir ${{github.workspace}}/ANTs/install
# tar -xf ANTsX-v2.4.3_windows.zip -C ${{github.workspace}}/ANTs/install/
- name: Install dependencies
run: |
python -m pip install --upgrade pip
ls
pip install git+https://github.com/dbouget/raidionics_rads_lib.git@software_test
pip install -r assets/requirements.txt
pip install matplotlib==3.3.4
pip install --force-reinstall --no-cache-dir pyside6
- name: Build software
run: |
pip install pyinstaller==5.13.2
mkdir tmp_dependencies
pyinstaller --log-level INFO --noconfirm --clean assets/main.spec
- name: Test executable
run: QT_QPA_PLATFORM="offscreen" ./dist/Raidionics/Raidionics & sleep 5; kill -INT %+
shell: bash
- name: Test GUI startup
run: cd ${{github.workspace}}/tests && python software_launch_test.py
- name: Make installer
run: |
makensis.exe assets/Raidionics.nsi
cp -r assets/Raidionics-1.2.2-win.exe dist/Raidionics-1.2.2-win.exe
- name: Upload package
uses: actions/upload-artifact@v3
with:
name: Package
path: ${{github.workspace}}/dist/Raidionics-*
if-no-files-found: error