Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Protected branches can't be force pushed #209

Closed
MylesBorins opened this issue May 3, 2017 · 2 comments
Closed

Protected branches can't be force pushed #209

MylesBorins opened this issue May 3, 2017 · 2 comments

Comments

@MylesBorins
Copy link
Contributor

So this is obviously by design / a feature... but it introduces a hiccup in the release flow. generally be rebase the staging branch against the release branch after a release. After doing this we force push.

This has been a bit of annoyances for backports... as they all end up requiring a rebase after a release.

Alternatively we could look at cherry-picking from the release branch to staging... but I also cringe at the idea of staging + release constantly drifting. Rebasing staging is by far the more elegant approach for keeping a clean history... but at a cost.

This release I simply unprotected the branch, force pushed, and then re-protected. This would not be possible for releasers who are not owners.

What do people think we should do?

@gibfahn
Copy link
Member

gibfahn commented May 3, 2017

Interesting that you can't choose whether protected branches can be force pushed to, maybe something we should raise with GitHub.

I think the rebasing is necessary though, if we start trying to cherry pick across then we lose the benefit of staging, as we can no longer trust that the staging branch is exactly the same as the vN.x branch.

Maybe a bot or a CI job that automated the process of removing, rebasing, and re-adding branch protection would work for non-owners.

@MylesBorins
Copy link
Contributor Author

the CI job would have to be an owner which I think is a non starter. We could also just leave it to owners to rebase... which isn't soooo unreasonable.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants