-
-
Notifications
You must be signed in to change notification settings - Fork 14
137 lines (135 loc) · 4.76 KB
/
central.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
name: Intiface Central Build
# Only build on master pushes for now, otherwise we'll eat CI.
on:
push:
branches:
- main
- dev
- ci
jobs:
windows:
runs-on: windows-latest
steps:
- uses: actions/checkout@v3
- name: rust toolchain
uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: stable
override: true
# - uses: Swatinem/rust-cache@v2
# with:
# workspaces: intiface-engine-flutter-bridge
# cache-targets: false
# cache-directories: .\build\windows\x64\Release\cargo
# prefix-key: rust-v0
- uses: subosito/flutter-action@v2
with:
channel: 'stable'
cache: true
cache-key: 'flutter-:os:-:channel:-:version:-:arch:-:hash:'
- run: flutter config --enable-windows-desktop
name: flutter config
- run: flutter build windows --release
name: flutter build
- name: Restore signing pfx
id: create-pfx
shell: pwsh
env:
PFX_CONTENT: ${{ secrets.NPLABS_WINDOWS_20210514_SIGNING_CERT }}
run: |
$pfxPath = Join-Path -Path $env:RUNNER_TEMP -ChildPath "cert.pfx";
$encodedBytes = [System.Convert]::FromBase64String($env:PFX_CONTENT);
Set-Content $pfxPath -Value $encodedBytes -AsByteStream;
Write-Output "::set-output name=PFX_PATH::$pfxPath";
- name: Sign Intiface Central Executable
shell: pwsh
env:
PFX_KEY: ${{ secrets.NPLABS_WINDOWS_20210514_SIGNING_KEY }}
run: |
$pfxPath = Join-Path -Path $env:RUNNER_TEMP -ChildPath "cert.pfx";
& "C:\Program Files (x86)\Windows Kits\10\bin\10.0.22000.0\x64\signtool.exe" sign /f $pfxPath /p "$env:PFX_KEY" /t http://timestamp.digicert.com /fd SHA256 .\build\windows\runner\Release\intiface_central.exe
- name: Build Innosetup Installer
shell: pwsh
run: |
iscc .\intiface-central-installer.iss
# - name: Sign Innosetup Installer
# shell: pwsh
# env:
# PFX_KEY: ${{ secrets.NPLABS_WINDOWS_20210514_SIGNING_KEY }}
# run: |
# $pfxPath = Join-Path -Path $env:RUNNER_TEMP -ChildPath "cert.pfx";
# & "C:\Program Files (x86)\Windows Kits\10\bin\10.0.22000.0\x64\signtool.exe" sign /f $pfxPath /p $env:PFX_KEY /t http://timestamp.digicert.com /fd SHA256 .\installer\intiface-central-installer.exe
- name: Archive production artifacts
uses: actions/upload-artifact@v3
with:
name: windows-installer
path: |
installer/intiface-central-installer.exe
# linux:
# runs-on: ubuntu-latest
# steps:
# - uses: actions/checkout@v3
# - name: rust toolchain
# uses: actions-rs/toolchain@v1
# with:
# profile: minimal
# toolchain: stable
# override: true
# - uses: Swatinem/rust-cache@v2
# with:
# workspaces: intiface-engine-flutter-bridge
# prefix-key: rust-v0
# - uses: subosito/flutter-action@v2
# with:
# channel: 'stable'
# cache: true
# cache-key: 'flutter-:os:-:channel:-:version:-:arch:-:hash:'
# - run: |
# sudo apt-get update -y
# sudo apt-get install -y ninja-build libudev-dev libgtk-3-dev
# - run: flutter config --enable-linux-desktop
# name: flutter config
# - run: flutter build linux --release
# name: flutter build
# - name: Zip Release
# run: zip -r intiface-central-linux-x64.zip build/linux/x64/release/bundle
# - name: Archive production artifacts
# uses: actions/upload-artifact@v3
# with:
# name: linux-zip
# path: ./intiface-central-linux-x64.zip
#
# macos:
# runs-on: macos-latest
# steps:
# - uses: actions/checkout@v3
# - name: rust toolchain
# uses: actions-rs/toolchain@v1
# with:
# profile: minimal
# toolchain: stable
# override: true
# - uses: Swatinem/rust-cache@v2
# with:
# workspaces: intiface-engine-flutter-bridge
# prefix-key: rust-v0
# - uses: subosito/flutter-action@v2
# with:
# channel: 'stable'
# cache: true
# cache-key: 'flutter-:os:-:channel:-:version:-:arch:-:hash:'
# - run: flutter config --enable-macos-desktop
# name: flutter config
# - run: flutter build macos --release
# name: flutter build
# - name: Zip Release
# run: zip -r intiface-central-macos-universal.zip build/macos/Build/Products/Release/intiface_central.app
# - name: Archive production artifacts
# uses: actions/upload-artifact@v3
# with:
# name: macos-zip
# path: ./intiface-central-macos-universal.zip
#
#
#