Skip to content

feat: add baseBranch option - #373

Closed
prenaissance wants to merge 3 commits into
changesets:mainfrom
prenaissance:main
Closed

feat: add baseBranch option#373
prenaissance wants to merge 3 commits into
changesets:mainfrom
prenaissance:main

Conversation

@prenaissance

Copy link
Copy Markdown

Closes #368

Change summary

This change adds a new action input baseBranch, which allows specifying the branch on which the PR will be opened on. This is useful for hotfixes. In my case, I trigger a release on merging to main, and this change would allow me to open a PR straight to main with the cherry-picked changes.

Specifications

A new input, baseBranch, can be specified to open the PR onto that branch. If not specified, the behavior will be as before, the PR would be opened on the branch the action runs on.

Example

Here's how running a hotfix workflow would look like:

hotfix_action

The full workflow can be seen here https://github.com/prenaissance/changesets-test/blob/master/.github/workflows/changesets.yml

@changeset-bot

changeset-bot Bot commented Jun 3, 2024

Copy link
Copy Markdown

⚠️ No Changeset found

Latest commit: 31ff97e

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@trueberryless trueberryless left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 🎉 after I took a quick look

Very cool improvement imho.

Could you maybe add the explaination of this change into the README.md tho? So the documentation is up-to-date...

@prenaissance

Copy link
Copy Markdown
Author

Accidentally pushed the wrong branch and the PR was closed automatically

@prenaissance prenaissance reopened this Nov 30, 2024
@prenaissance

Copy link
Copy Markdown
Author

Thanks for the feedback @trueberryless. I added the new action input in the README. Let me know if an example with a full workflow is needed.

@trueberryless trueberryless left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me 🎉

I'll leave the decision for an additional example with the baseBranch option to the actual maintainers, they know it the best...

@baruchiro

Copy link
Copy Markdown

What about this?

Is this project still alive?

@bluwy

bluwy commented Jul 28, 2026

Copy link
Copy Markdown
Member

#368 (comment)

@bluwy bluwy closed this Jul 28, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Suggestion: add input to specify the target branch

4 participants