diff --git a/build/templates/build-number.yml b/build/templates/build-number.yml index 51269035..bdbb96be 100644 --- a/build/templates/build-number.yml +++ b/build/templates/build-number.yml @@ -4,10 +4,7 @@ inputs: targetType: inline script: | - # Get the current date and time in 'yyyyMMddHHmm' format - $dateTime = Get-Date -Format "yyyyMMddHHmm" - - $buildNumber = $dateTime + $buildNumber = [int]$(Build.BuildId) Write-Host "##vso[task.setvariable variable=BuildNumber]$buildNumber" Write-Host "Build number: $BuildNumber" \ No newline at end of file