Sync eng/common directory with azure-sdk-tools for PR 13102 (#6851)

* Added forRelease input parameter

* Added 'forRelease' to template

* Added log

---------

Co-authored-by: ray chen <raychen@microsoft.com>
This commit is contained in:
Azure SDK Bot 2025-12-02 14:34:01 -08:00 committed by GitHub
parent 20ee0acdf5
commit 243b4de513
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 9 additions and 2 deletions

View File

@ -4,6 +4,9 @@ parameters:
- name: Condition
type: string
default: succeeded()
- name: ForRelease
type: boolean
default: false
steps:
- task: Powershell@2
@ -11,6 +14,7 @@ steps:
filePath: $(Build.SourcesDirectory)/eng/common/scripts/Verify-ChangeLogs.ps1
arguments: >
-PackagePropertiesFolder '${{ parameters.PackagePropertiesFolder }}'
-ForRelease $${{ parameters.ForRelease }}
pwsh: true
displayName: Verify ChangeLogEntries
condition: ${{ parameters.Condition }}

View File

@ -1,7 +1,8 @@
# Wrapper Script for ChangeLog Verification in a PR
[CmdletBinding()]
param (
[String]$PackagePropertiesFolder
[String]$PackagePropertiesFolder,
[boolean]$ForRelease = $False
)
Set-StrictMode -Version 3
@ -33,7 +34,9 @@ foreach($propertiesFile in $packageProperties) {
continue
}
$validChangeLog = Confirm-ChangeLogEntry -ChangeLogLocation $PackageProp.ChangeLogPath -VersionString $PackageProp.Version -ForRelease $false
Write-Host "Verifying changelog for $($PackageProp.Name)"
$validChangeLog = Confirm-ChangeLogEntry -ChangeLogLocation $PackageProp.ChangeLogPath -VersionString $PackageProp.Version -ForRelease $ForRelease
if (-not $validChangeLog) {
$allPassing = $false