Working
Working
- name: 'asyncTimeout'
type: number
default: 3600
- name: 'connectionString'
type: string
- name: 'gitUserEmail'
type: string
- name: 'SolutionInternalName'
type: string
- name: 'SolutionVersionPreFix'
type: string
steps:
- checkout: self
persistCredentials: true
- task: NuGetToolInstaller@1
displayName: 'Use NuGet'
- task: NuGetCommand@2
displayName: 'Install pac'
inputs:
command: custom
arguments: 'install Microsoft.PowerApps.CLI -OutputDirectory pac'
- powershell: |
$pacNugetFolder = Get-ChildItem "pac" | Where-Object {$_.Name -match
"Microsoft.PowerApps.CLI."}
# Solutions logic #
- task: PowerPlatformSetSolutionVersion@2 #Set Version in DEV with unique
Build Number included
displayName: 'Solution Versioning'
inputs:
authenticationType: 'PowerPlatformSPN'
PowerPlatformSPN: ${{ parameters.connectionString }}
SolutionName: '${{ parameters.SolutionInternalName }}'
SolutionVersionNumber: '${{ parameters.SolutionVersionPrefix }}.$
(Build.BuildNumber)'
- powershell: |
$env:PATH = $env:PATH + ";" + "$(pacPath)"
pac solution create-settings --solution-zip "$
(System.DefaultWorkingDirectory)/$(GitDirectoryExportedSolutions)/$
{{ parameters.SolutionInternalName }}UM.zip" --settings-file "$
(GitDirectoryExportedSolutions)\DeploymentSettings\$
{{ parameters.SolutionInternalName }}.json"
displayName: "Extract Solution Settings, Environment Variables and
Connection References"