Skip to content

Commit

Permalink
Sync scripts\make-changelog.ps1
Browse files Browse the repository at this point in the history
  • Loading branch information
SyncFileContents authored and SyncFileContents committed Jan 3, 2025
1 parent a68d97f commit d49e779
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions scripts/make-changelog.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,12 @@ function MakeNotesForRange {
$SEARCH_TAG = "$FROM_MAJOR_VERSION_NUMBER.0.0.0"
}

# Handle the case where the version is the same but the prerelease number has been dropped
if ($TO_VERSION_MAJOR -eq $FROM_VERSION_MAJOR -and $TO_VERSION_MINOR -eq $FROM_VERSION_MINOR -and $TO_VERSION_PATCH -eq $FROM_VERSION_PATCH -and $TO_VERSION_PRERELEASE -eq "0" -and $FROM_VERSION_PRERELEASE -ne "0") {
$VERSION_TYPE = "patch"
$SEARCH_TAG = "$TO_VERSION_MAJOR.$TO_VERSION_MINOR.$FROM_PATCH_VERSION_NUMBER.0"
}

if ($SEARCH_TAG.Contains("-")) {
$SEARCH_TAG = $FROM_TAG
}
Expand Down

0 comments on commit d49e779

Please sign in to comment.