Trilinos icon indicating copy to clipboard operation
Trilinos copied to clipboard

Framework: add action to delete merge branches?

Open jhux2 opened this issue 1 year ago • 6 comments

Question

@trilinos/framework Is it be possible to add a github action to delete branches that have been auto-merged? Right now, when a PR is automerged and the branch lives in the Trilinos repo, the author has to remember to delete the branch. As a result, there are a lot of dead branches, including merges to master. (Alternatively, the project could require branches to be in the author's own fork.)

jhux2 avatar Sep 15 '23 16:09 jhux2

It could be controlled via a Label, in case you didn't want it deleted.

csiefer2 avatar Sep 15 '23 18:09 csiefer2

Here is an action that does delete on merge:

https://github.com/marketplace/actions/delete-merged-branch

csiefer2 avatar Sep 15 '23 18:09 csiefer2

We could also set the repo to just do that (thanks for the functionality, Microsoft!)

https://docs.github.com/en/repositories/configuring-branches-and-merges-in-your-repository/configuring-pull-request-merges/managing-the-automatic-deletion-of-branches

csiefer2 avatar Sep 15 '23 18:09 csiefer2

I'm fully in favor of this. I'll try to remember to bring this up at TUG next week, if we get support then we can probably just turn it on.

I'll also note that I'm fully in favor of forcing the fork workflow so that the central repository does not contain WIP from developers.

sebrowne avatar Oct 26 '23 17:10 sebrowne

Adding to the list for open discussion topics.

ccober6 avatar Oct 26 '23 19:10 ccober6

Putting on the agenda for the Operational Leadership meeting this week.

ccober6 avatar Feb 19 '24 18:02 ccober6