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

test: add a line #266

Merged
merged 2 commits into from
Aug 6, 2023
Merged

test: add a line #266

merged 2 commits into from
Aug 6, 2023

Conversation

korthout
Copy link
Owner

@korthout korthout commented Aug 6, 2023

@korthout korthout merged commit 6da0462 into main Aug 6, 2023
@korthout korthout deleted the case4-mainline branch August 6, 2023 16:00
@korthout
Copy link
Owner Author

korthout commented Aug 6, 2023

/backport

@github-actions
Copy link
Contributor

github-actions bot commented Aug 6, 2023

Backport failed for case4-target-branches, because it was unable to cherry-pick the commit(s).

Please cherry-pick the changes locally.

git fetch origin case4-target-branches
git worktree add -d .worktree/backport-266-to-case4-target-branches origin/case4-target-branches
cd .worktree/backport-266-to-case4-target-branches
git checkout -b backport-266-to-case4-target-branches
ancref=$(git merge-base 754e914ec3a9bdb7cbbc45a586074b5df66799f1 f2230426140cf8fc4c410f68d14a8410ce420ac5)
git cherry-pick -x $ancref..f2230426140cf8fc4c410f68d14a8410ce420ac5

@korthout
Copy link
Owner Author

korthout commented Aug 6, 2023

So, the behavior is as before (the above ran without a default_mainline). The next run will have default_mainline: 1.

/backport

@github-actions
Copy link
Contributor

github-actions bot commented Aug 6, 2023

Successfully created backport PR for case4-target-branches:

@korthout
Copy link
Owner Author

korthout commented Aug 6, 2023

Okay, so that worked. Let's see how it runs with default_mainline: 2

/backport

@github-actions
Copy link
Contributor

github-actions bot commented Aug 6, 2023

Backport failed for case4-target-branches, because it was unable to cherry-pick the commit(s).

Please cherry-pick the changes locally.

git fetch origin case4-target-branches
git worktree add -d .worktree/backport-266-to-case4-target-branches origin/case4-target-branches
cd .worktree/backport-266-to-case4-target-branches
git checkout -b backport-266-to-case4-target-branches
ancref=$(git merge-base 754e914ec3a9bdb7cbbc45a586074b5df66799f1 f2230426140cf8fc4c410f68d14a8410ce420ac5)
git cherry-pick -x $ancref..f2230426140cf8fc4c410f68d14a8410ce420ac5

@korthout
Copy link
Owner Author

korthout commented Aug 6, 2023

Okay, that did not work because the mainline is applied to all cherry-picks:

git cherry-pick -x --mainline=2 837d73b f223042
error: commit 837d73b does not have parent 2

So, default_mainlines of >1 are not supported at this time. It may be useful to add in the future, that would mean that we'd need to use the mainline setting only when cherry-picking merge commits explicitly. This can be added later while keeping behavior the same.

@korthout
Copy link
Owner Author

korthout commented Aug 6, 2023

Another idea is to allow specifying 0 as the mainline, where merge commits are skipped. This can also be supported later.

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.

1 participant