Skip to content
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

Release git history borked #128

Open
3 tasks
PaulHax opened this issue Oct 9, 2024 · 6 comments · May be fixed by #127
Open
3 tasks

Release git history borked #128

PaulHax opened this issue Oct 9, 2024 · 6 comments · May be fixed by #127

Comments

@PaulHax
Copy link
Collaborator

PaulHax commented Oct 9, 2024

Looks like we forgot to merge 0.3.2 release back into main. When I erroniously rebaseed main to release for the 0.4.0 release, the merge from release to main will add duplicate commits.

@vicentebolea
Copy link
Collaborator

There is a CI job that merges release to main after every commit in release. Unfortunately it did not trigger since there has been a change in the branches settings for push requirements.

The error was: Changes must be made through a pull request. // See: https://docs.github.com/rest/branches/branches#merge-a-branch I have changed the settings to solve this.

The rationale for having a release branch is that we wanted to have an state in master that was different to the release. This was specially important for features that took multiple PRs. Having a release branch gives us control into what goes in a release (which it was needed).

@PaulHax
Copy link
Collaborator Author

PaulHax commented Oct 10, 2024

Right now after 0.4.0, when I test merge release back to main, I see many duplicate commits. How to solve that?

Is it OK that we don't merge release back to main after semantic release makes its version commit? Methinks right now we don't get that audo merge back until we decide to make another pr/merge/release.

@vicentebolea
Copy link
Collaborator

There are not duplicated commits, there are either backported commits to the release branch (that was the reason of having a release branch) or you are seeing a merge commit. We want to always merge release to main (we do an -s ours merge) to avoid future merge conflicts.

@PaulHax
Copy link
Collaborator Author

PaulHax commented Oct 10, 2024

Is it OK that we don't automaticly merge release back to main after semantic release makes its version commit?

Do we need to merge release back to main for 0.4.0 right now?

@vicentebolea
Copy link
Collaborator

Is it OK that we don't automaticly merge release back to main after semantic release makes its version commit?

It is safer to merge after releases so that releases are reachable from main and also we avoid potential merge conflicts in the future.

Do we need to merge release back to main for 0.4.0 right now?

it is already merged 1c9359e

@vicentebolea
Copy link
Collaborator

You might want to close this since this was solved by restoring the github branch settings.

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 a pull request may close this issue.

2 participants