Skip to content

Fix: CI. Add Close to Tray dialog and improve shutdown handling #10

Fix: CI. Add Close to Tray dialog and improve shutdown handling

Fix: CI. Add Close to Tray dialog and improve shutdown handling #10

Workflow file for this run

name: Canary
on:
push:
branches-ignore:
- l10n_develop
- master
- release
- dependabot/**
paths-ignore:
- '.gitattributes'
- '.github/**'
- '.gitignore'
- '.gitmodules'
- '**.md'
- 'LICENSE'
- '**.yml'
env:
VCPKG_BINARY_SOURCES: "clear;x-gha,readwrite"
jobs:
build:
runs-on: windows-2025-vs2026
strategy:
matrix:
configuration: [Release]
platform: [x64, ARM64]
permissions:
contents: write
packages: write
steps:
- uses: actions/checkout@v5
with:
submodules: recursive
- uses: microsoft/setup-msbuild@v2
- uses: nuget/setup-nuget@v2
- name: Set up vcpkg
working-directory: ${{env.VCPKG_INSTALLATION_ROOT}}
run: vcpkg integrate install
- name: Restore NuGet
run: nuget restore OpenNet.slnx
shell: pwsh
- name: cache nuget packages
uses: actions/cache@v5
with:
path: ~/.nuget/packages
- name: Restore Certificate
run: |
$bytes = [Convert]::FromBase64String("${{ secrets.PFX_CERT_BASE64 }}")
[IO.File]::WriteAllBytes("cert.pfx", $bytes)
shell: pwsh
- name: Build MSIX
run: |
msbuild OpenNet.slnx `
/p:Configuration=${{ matrix.configuration }} `
/p:Platform=${{ matrix.platform }} `
/p:UapAppxPackageBuildMode=SideloadOnly `
/p:AppxPackageSigningEnabled=true `
/p:PackageCertificateKeyFile=../cert.pfx `
/p:PackageCertificatePassword="${{ secrets.PFX_PASSWORD }}" `
/m
shell: pwsh
- name: Generate Date
run: |
$date = Get-Date -Format yyyyMMdd
Add-Content -Path $Env:GITHUB_ENV -Value "DATE=$date"
shell: pwsh
- name: Zip Package
run: |
Compress-Archive `
-Path "Packages/*${{ matrix.platform }}*" `
-DestinationPath "OpenNet.Canary_${{ env.DATE }}_${{ matrix.platform }}.zip"
shell: pwsh
- name: 7z Package
run: |
if (-not (Get-Command 7z -ErrorAction SilentlyContinue)) {
choco install 7zip -y
}
7z a -t7z -mx=9 `
"OpenNet.Canary_${{ env.DATE }}_${{ matrix.platform }}.7z" `
"Packages\*${{ matrix.platform }}*"
shell: pwsh
- name: Upload Canary Artifact
uses: actions/upload-artifact@v6
with:
name: OpenNet.Canary_${{ env.DATE }}_${{ matrix.platform }}
path: |
OpenNet.Canary_${{ env.DATE }}_${{ matrix.platform }}.zip
OpenNet.Canary_${{ env.DATE }}_${{ matrix.platform }}.7z