Skip to content

Commit a968613

Browse files
azure-sdktadelesh
andauthored
fix: body is too long when create github release (Azure#22522)
Co-authored-by: tadelesh <[email protected]>
1 parent 4652858 commit a968613

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

eng/common/scripts/artifact-metadata-parsing.ps1

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,10 @@ function CreateReleases($pkgList, $releaseApiUrl, $releaseSha) {
1111
if ($pkgInfo.ReleaseNotes -ne $null) {
1212
$releaseNotes = $pkgInfo.ReleaseNotes
1313
}
14+
# As github api limit the body param length with 125000 characters, we have to truncate the release note if needed.
15+
if ($releaseNotes.Length -gt 124996) {
16+
$releaseNotes = $releaseNotes.SubString(0, 124996) + " ..."
17+
}
1418

1519
$isPrerelease = $False
1620

0 commit comments

Comments
 (0)