Ubuntu automatically pull from Github repo

Sosa picture Sosa · Jul 2, 2015 · Viewed 11.3k times · Source

I installed git on my server but I want it to pull from my github repo whenever I push the changes I made locally.

I've looked into hooks but it's very confusing and I can't find any tutorials. Does anyone know how to do that?

Answer

VonC picture VonC · Jul 2, 2015

I want my server to pull from the repo after each commit

That looks like a webhook: your server would listen to a pull event (JSON payload) emitted by GitHub.

You will find many example of listener, like zenhacks/github-webhook-listener in CoffeeScript.