Created
June 30, 2022 18:06
-
-
Save andreas-nesheim/dc5421ef72287d12640146e60ef8501c to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
trigger: | |
- master | |
pool: | |
vmImage: 'windows-latest' | |
variables: | |
buildConfiguration: 'Release' | |
outputDirectory: '$(Build.BinariesDirectory)/$(buildConfiguration)' | |
steps: | |
- task: CmdLine@2 | |
inputs: | |
script: 'dotnet workload install maui' | |
- task: DotNetCoreCLI@2 | |
inputs: | |
command: 'publish' | |
publishWebProjects: false | |
projects: 'MyMAUIProject.sln' | |
arguments: '-c $(buildConfiguration) -f:net6.0-windows10.0.19041.0' | |
zipAfterPublish: false | |
modifyOutputPath: false | |
- task: DownloadSecureFile@1 | |
inputs: | |
secureFile: 'mymauiwindowscert.pfx' | |
- task: CopyFiles@2 | |
inputs: | |
SourceFolder: '$(Agent.BuildDirectory)' | |
Contents: '**/MyMAUIProject*.msix' | |
TargetFolder: '$(Build.ArtifactStagingDirectory)' | |
flattenFolders: true | |
- script: '"C:\Program Files (x86)\Windows Kits\10\App Certification Kit\SignTool" sign /fd SHA256 /f $(Agent.TempDirectory)/mymauiwindowscert.pfx /p sup3rs3cr3tp4ssw0rd $(Build.ArtifactStagingDirectory)\MyMauiProject_1.0.0.0_x64.msix' | |
displayName: 'Sign MSIX Package' | |
- task: PublishBuildArtifacts@1 | |
inputs: | |
PathtoPublish: '$(Build.ArtifactStagingDirectory)' | |
ArtifactName: 'drop' | |
publishLocation: 'Container' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment