GitHub Branch Policies?

Hi everyone!

I’m trying to see if GitHub has a feature similar to VSTS (Microsoft) where you can institute branch policies , or requirements that prevent direct pushing of commits to a particular branch. In this case, users would have to make a pull-request in order to push code into its upstream.

Is there any option like that?

Hi @ryhsh72,

Yes, GitHub does have something like that! You can implement this sort or restriction through GitHub’s protected branches. You can even require that all pull requests require reviews before they get merged into the protected branch.

Does that help?

Thanks!

1 Like

That is exactly what I needed, thank you @that-pat! :smiley:

You’re very welcome!