Add support to git rebase --autosquash from the ui
how to reproduce
configure project:
-
enable approvals in project -
enable reset approvals on push: https://gitlab.delfi.net/help/user/project/merge_requests/merge_request_approvals#resetting-approvals-on-push
typical flow
- developer makes commit
- reviewer requests changes
- developer makes
fixup!
commit - reviewer gives approval
but merge should not be performed before the fixup commits are flattened.
doing normal rebase from UI does not reset approval, but doing git rebase -i --autosquash
from commandline resets the approvals.
the enhancement
the enhancement would be to make the autosquash rebase from the UI, or gitlab able to understand that user made a push that only squashed commits, did not perform any other changes.
maybe, if it's easier to implement, is to require base branch to be exactly the same before the push after autosquash:
- rebase against base branch. push
- rebase against target branch from the ui
- approval is preserved
extra considerations:
- account only diffs, or commit message, authors, any other metadata?