Skip to content

Create dotnet-framework.yml #1

Create dotnet-framework.yml

Create dotnet-framework.yml #1

name: TransportAgents .NETFramework Build
on:
push:
branches: [ "master" ]
jobs:
build:
runs-on: windows-latest
env:
Solution_Name: TransportAgents.sln
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup MSBuild.exe
uses: microsoft/setup-msbuild@v2
#- name: Setup NuGet
# uses: nuget/setup-nuget@v2
- name: Build Solution
run: |
msbuild.exe $env:Solution_Name /p:platform="Any CPU" /p:configuration="Release"
# Decode the base 64 encoded pfx and save the Signing_Certificate
#- name: Decode the pfx
# run: |
# $pfx_cert_byte = [System.Convert]::FromBase64String("${{ secrets.Base64_Encoded_Pfx }}")
# $certificatePath = Join-Path -Path $env:Wap_Project_Directory -ChildPath GitHubActionsWorkflow.pfx
# [IO.File]::WriteAllBytes("$certificatePath", $pfx_cert_byte)
# Create the app package by building and packaging the Windows Application Packaging project
#- name: Create the app package
# run: msbuild $env:Wap_Project_Path /p:Configuration=$env:Configuration /p:UapAppxPackageBuildMode=$env:Appx_Package_Build_Mode /p:AppxBundle=$env:Appx_Bundle /p:PackageCertificateKeyFile=GitHubActionsWorkflow.pfx /p:PackageCertificatePassword=${{ secrets.Pfx_Key }}
# env:
# Appx_Bundle: Always
# Appx_Bundle_Platforms: x86|x64
# Appx_Package_Build_Mode: StoreUpload
# Configuration: ${{ matrix.configuration }}
# Remove the pfx
#- name: Remove the pfx
# run: Remove-Item -path $env:Wap_Project_Directory\GitHubActionsWorkflow.pfx