-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Feature] Add "Create Release PR" composite action #7
Conversation
f3ae9f3
to
c5e2980
Compare
6bbc762
to
dfe2c22
Compare
dfe2c22
to
6c87df5
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't have any big concerns for this 🙏
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @luongvo, this will help me to create the release PRs for more than 15 repos on the GT API 💪
812df8d
to
5cd6cc6
Compare
@@ -84,12 +84,19 @@ runs: | |||
git checkout -b $RELEASE_BRANCH | |||
git push origin $RELEASE_BRANCH -f | |||
|
|||
# Add milestone if available | |||
if [ -n "${{ steps.find_milestone.outputs.milestone_url }}" ]; then |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
FYI: if milestone_url
is found, that means the milestone from the release version is available from the repo.
8a28ee6
to
d2f913f
Compare
@hoangmirs Please have your final review on this PR, please 👋 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🎉
What happened 👀
Create a new Composite workflow
create_release_pr
to automate the Release pull request creation:tag
on the main branch to the latest HEAD on thedevelop
.Insight 📝
To generate the release change log like our Release PR, use https://github.com/mikepenz/release-changelog-builder-action. It helps us generate the change log from a config file, like what we did with https://github.com/release-drafter/release-drafter from [#100] Add new workflow to generate release note and version tag automatically android-templates#245. However, https://github.com/mikepenz/release-changelog-builder-action does not require adding its app to our GitHub organization and can be reused to generate the change log texts for App Distribution release notes or even create releases like release-drafter.
To create the pull request by checking out a new release branch from develop, we can NOT use https://github.com/peter-evans/create-pull-request because it requires stage changes to create PR. Instead, I realized we can create PR using GitHub CLI 🤩
Before creating the release PR, we must check out a new release branch from the current
develop
.To fetch corresponding
milestone
info (assuming the milestone matches the current version name), while GitHub CLI does not support milestone API officially, we can use an extension called https://github.com/valeriobelli/gh-milestone 🤩This command helps us to get the milestone URL from the milestone name = current version:
Proof Of Work 📹
Sample usage:
A sample generated Release PR for the current
develop
👉main
nimblehq/android-templates#561 🎉Run log: https://github.com/nimblehq/android-templates/actions/runs/6976881886/job/18985941279