sorenlouv / backport

A simple CLI tool that automates the process of backporting commits on a GitHub repo
https://github.com/sqren/backport/blob/main/docs/config-file-options.md
Apache License 2.0
241 stars 57 forks source link

Add support for dynamic `sourcePRLabels` #453

Open jumaffre opened 1 year ago

jumaffre commented 1 year ago

Similar to #391 but for sourcePRLabels.

The use case is that we have N active release branches that we'd like to backport to, but it's possible that automatic backport to one of the release branches fails for some reason (e.g. merge conflict) and succeeds on another. Currently, my understanding is that in this degraded scenario, the source PR will still be marked with the sourcePRLabels labels.

Instead, we wondered if it'd be possible to mark the source PR with individual labels, per release branch (e.g. N-backported, N-1-backported) so that we can easily identify backports that have failed on some release branches but not on others.

We've been using backport and the associated GitHub Action on https://github.com/microsoft/CCF for a few months/release cycles now and it's saved us lots of manual effort to keep a growing number of release branches up to date. We think this would be a great feature for repos that have more than 1 branch to backport to, but let us know if there's another workaround for this.