azure-sdk-for-cpp/eng/common/scripts/Verify-ChangeLogs.ps1
Azure SDK Bot b4020493c4
Sync eng/common directory with azure-sdk-tools for PR 8754 (#5884)
* more compatibility with expanding/contracting packages. add ability for packages to have DependentPackages that must be included in the set of packages that should be built given a changeset


---------

Co-authored-by: Scott Beddall <scbedd@microsoft.com>
Co-authored-by: Scott Beddall <45376673+scbedd@users.noreply.github.com>
Co-authored-by: Wes Haggard <weshaggard@users.noreply.github.com>
2024-08-07 16:18:42 -07:00

32 lines
770 B
PowerShell

# Wrapper Script for ChangeLog Verification in a PR
[CmdletBinding()]
param (
[String]$PackagePropertiesFolder
)
Set-StrictMode -Version 3
. (Join-Path $PSScriptRoot common.ps1)
# find which packages we need to confirm the changelog for
$packageProperties = Get-ChildItem -Recurse "$PackagePropertiesFolder" *.json
# grab the json file, then confirm the changelog entry for it
$allPassing = $true
foreach($propertiesFile in $packageProperties) {
$PackageProp = Get-Content -Path $propertiesFile | ConvertFrom-Json
$validChangeLog = Confirm-ChangeLogEntry -ChangeLogLocation $PackageProp.ChangeLogPath -VersionString $PackageProp.Version -ForRelease $false
if (-not $validChangeLog) {
$allPassing = $false
}
}
if (!$allPassing)
{
exit 1
}
exit 0