-
Notifications
You must be signed in to change notification settings - Fork 1.1k
65 lines (62 loc) · 1.6 KB
/
publish-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
name: Publish Windows Setup
on:
push:
branches:
- master
tags:
- v*
jobs:
build:
runs-on: windows-2019
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Setup Python
uses: actions/setup-python@v2
with:
python-version: '3.8.1'
architecture: 'x64'
- uses: Jimver/cuda-toolkit@v0.2.4
id: cuda-toolkit
with:
cuda: '11.4.0'
- name: Setup cmake
uses: jwlawson/actions-setup-cmake@v1.13
with:
cmake-version: '3.24.x'
- name: Extract code signing cert
id: code_sign
uses: timheuer/base64-to-file@v1
with:
fileName: 'comodo.pfx'
encodedString: ${{ secrets.CODE_SIGNING_CERT }}
- name: Install venv
run: |
python -m pip install virtualenv
- name: Build sources
run: |
python configure.py build
- name: Free up space
run: |
rmdir SuperBuild\download /s /q
rmdir SuperBuild\build /s /q
shell: cmd
- name: Create setup
env:
CODE_SIGN_CERT_PATH: ${{ steps.code_sign.outputs.filePath }}
run: |
python configure.py dist --code-sign-cert-path $env:CODE_SIGN_CERT_PATH
- name: Upload Setup File
uses: actions/upload-artifact@v4
with:
name: Setup
path: dist\*.exe
- name: Upload Setup to Release
uses: svenstaro/upload-release-action@v2
if: startsWith(github.ref, 'refs/tags/')
with:
repo_token: ${{ secrets.GITHUB_TOKEN }}
file: dist/*.exe
file_glob: true
tag: ${{ github.ref }}
overwrite: true