Can i trigger GitLab to push revision?


Hello everyone,
My Company has decided on switching to Phabricator for code review purposes,
and recently I was asked to prevent a push command as long as the revision not approved.

I think that I should use the pre-push hook, but I encountered difficulties…

Has any of you made a similar transition and can guide me?



If your developers are pushing directly to GitLab, then you need to install some pre-push hook in GitLab, which will prevent the forbidden pushes. You’ll need to implement the logic of that yourself.


Thanks for your reply,
installing hook is the way i chose, but now I’m having a new problem…
Can I ask new question?
There is some way to trigger GitLab to push pending refs?

For example, when a developer A finished his commits, and decided to push them into git repository hosted in GitLab, the pre-push hook will send diff request to the relevant code reviewer(that can be done easily), and only when the code reviewer will accept the revision, then the Phabricator will trigger GitLab to push developer
A commits.

Thank you very much!


That sounds very hard to implement, but maybe not impossible. is talking about some similar workflows, implemented by changing the git server behavior.


Thanks for your reply!


is there a guide on how to integrate Phabricator with gitlab? is it even possible?


I think is what you’re looking for - just read “github” as “github” all around.


Hi Eyal

Thank you for your prompt reply: )

I really mean gitlab ( not hub)

Did you mean the integration for gitlab and github with phabricator is identical?



That’s what we are currently using …


yes, as far as Phabricator is concerned, there’s no difference between GitHub and GitLab.