Skip to content

Instantly share code, notes, and snippets.

@andreas-nesheim
Created July 20, 2022 20:35
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save andreas-nesheim/8bb8479ec4d0291e66598c64401a0cbd to your computer and use it in GitHub Desktop.
Save andreas-nesheim/8bb8479ec4d0291e66598c64401a0cbd to your computer and use it in GitHub Desktop.
name: .NET MAUI (Windows)
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
jobs:
build:
runs-on: windows-latest
steps:
- uses: actions/checkout@v3
- name: Setup .NET
uses: actions/setup-dotnet@v2
with:
dotnet-version: 6.0.x
- name: Install MAUI workload
run: dotnet workload install maui
- name: Decrypt PFX File
run: |
echo "${{ secrets.WINDOWS_PFX_FILE }}" > cert.pfx.asc
certutil -decode cert.pfx.asc cert.pfx
- name: Add Cert to Store
run: certutil -user -q -p ${{ secrets.WINDOWS_PFX_PASSWORD }} -importpfx cert.pfx NoRoot
- name: Build
run: dotnet publish -c Release -f:net6.0-windows10.0.19041.0 /p:GenerateAppxPackageOnBuild=true /p:AppxPackageSigningEnabled=true /p:PackageCertificateThumbprint="${{ secrets.WINDOWS_PFX_THUMBPRINT }}"
- name: Upload Build Artifacts
uses: actions/upload-artifact@v3.1.0
with:
path: .\**\AppPackages\**\*.*
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment