Allow splitting MRs by creating a new branch and MR from a commit in the MR
Usecases
This is for splitting an MR into two parts. So you can still work on the original MR, but get a subset merged before then.
Proposal
- From an MR's commits tab, pick a commit to create a new MR from. This will create an MR for everything up to that commit. So it's like, 'the first three commits are fine, the rest need some thought' and it's easy to split those first three out.
- We don't do anything fancy, just create a branch (perhaps existing source branch + short-SHA?) and an MR.
- The description could either copy from the original, or be a template.
- Labels, assignee, milestone, etc. would copy from the original.
- We'd copy MR settings (like the remove source branch checkbox).
Design
It takes cues from the button groups available in the pipeline list view and from the "resolved discussions" button.
Let's apply that styling to each commit row:
- Show a tooltip on the button stating: `Split of from this commit into a new merge request)
Edited by Dimitrie Hoekstra