Skip to content

Commit

Permalink
chore: ensure automated v6 release compared to v6 (#3149)
Browse files Browse the repository at this point in the history
  • Loading branch information
mweberxyz committed Apr 24, 2024
1 parent 179237d commit 8dd32ef
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
4 changes: 3 additions & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,9 @@ jobs:
repo
})
if (versionTag !== releases[0]?.tag_name) {
const previousRelease = releases.find((r) => r.tag_name.startsWith('v6'))
if (versionTag !== previousRelease?.tag_name) {
return versionTag
}
Expand Down
4 changes: 3 additions & 1 deletion scripts/release.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,14 @@ const generateReleaseNotes = async ({ github, owner, repo, versionTag, defaultBr
repo
})

const previousRelease = releases.find((r) => r.tag_name.startsWith('v6'))

const { data: { body } } = await github.rest.repos.generateReleaseNotes({
owner,
repo,
tag_name: versionTag,
target_commitish: defaultBranch,
previous_tag_name: releases[0]?.tag_name
previous_tag_name: previousRelease?.tag_name
})

const bodyWithoutReleasePr = body.split('\n')
Expand Down

0 comments on commit 8dd32ef

Please sign in to comment.