Alireza
Alireza

Reputation: 4516

Restricting user's push commands privileges

How can I not allow the users to make pushes that are going to create a new branch in remote repository?
And is there anyway not to let the user push to a certain remote branch in github ,e.g restrict him/her from pushing to the origin/master branch? ( Considering the account is not an organization account. I was used to do this using gitolite, but since it's github , i don't seem to know how's that done )

Upvotes: 0

Views: 192

Answers (1)

Adam Dymitruk
Adam Dymitruk

Reputation: 129526

You can't run custom scripts on github. That would allow malicious users to compromise their servers. If you want this restriction to help them, then you can have them use a local git hook. If you want this restriction to be absolute because of security concerns, then you can't have them push to github.

Upvotes: 2

Related Questions