In some cases, such as simple configuration changes, users create batch changes with lots of small changesets that they expect to merge themselves after checks and/or review passes. Instead of regularly checking batch changes for changesets that are ready to merge, changesets could be merged automatically once conditions are met.
Allow a batch change to opt into auto-merging changesets on conditions:
When the CI tests pass
When all assigned reviewers are satisfied
When the change can merge cleanly
Any or all of the above
MVP
We can scope this down to allowing auto-merge if review and check pass (per our current definition).
If merge cannot be done cleanly, add a comment in the issue "Batch Changes attempted to merge but xxx" and report that somewhere (maybe in the bulk action or logs tab).
It can be set with a CLI flag (src batch remote --automerge and src batch apply --automerge) and UI checkbox that allow, at apply to enable auto-merge (this is a needs-design, maybe a spec param is better). In later versions "enable auto-merge" could be a bulk action.
We need a way to signify to users that auto-merge is on on a batch change, and to disable it
We'll need pings, so this needs-RFC. The right metric is probably # batch changes with automerge created
Hey, @sourcegraph/batchers (@eseliger @mrnugget @LawnGnome @courier-new @adeola-ak @malomarrec @chrispine) - we have been mentioned. Let's take a look.
Problem to solve
In some cases, such as simple configuration changes, users create batch changes with lots of small changesets that they expect to merge themselves after checks and/or review passes. Instead of regularly checking batch changes for changesets that are ready to merge, changesets could be merged automatically once conditions are met.
See product gap
Solution summary
Allow a batch change to opt into auto-merging changesets on conditions:
MVP
review
andcheck
pass (per our current definition).src batch remote --automerge
andsrc batch apply --automerge
) and UI checkbox that allow, atapply
to enable auto-merge (this is aneeds-design
, maybe a spec param is better). In later versions "enable auto-merge" could be a bulk action.We'll need pings, so this
needs-RFC
. The right metric is probably# batch changes with automerge created
Customers we're iterating with
Success criteria
Delivery plan
TBD