On 15 September 2014 02:40, Michał Górny <mgo...@gentoo.org> wrote:

> However, I'm wondering if it would be possible to restrict people from
> accidentally committing straight into github (e.g. merging pull
> requests there instead of to our main server).
>


Easy.

Put the Gentoo repo in its own group.
Don't give anyone any kinds of permissions on it.
Have only one approved account for the purpose of pushing commits.
Have a post-push hook that replicates to github as that approved account

=> Github is just a read only mirror, any pull reqs submitted there will be
fielded and pushed to gentoo directly.

Only downside there is the way github pull reqs work is if the final SHA1's
that hit tree don't match, the pull req doesn't close.

Solutions:

- A) Have somebody tasked with reaping old pull reqs with permissions
granted. ( Uck )
- B) Always use a merge of some kind to mark the pull req as dead ( for
instance, an "ours" merge to mark the branch as deprecated )

Both of those options are kinda ugly.



-- 
Kent

*KENTNL* - https://metacpan.org/author/KENTNL

Reply via email to