1

I need your help !

How to download the updated files in github project (not all files) using git hook api when project members commiting the new version ?

JSmith
  • 31
  • 1
  • 6

1 Answers1

2

The idea is to register a webhook for your repo, which will emit a JSON payload that you would listen.
You can register a webhook for push event

The listener depends on your local environment.
For example, you have Introducing Gith - GitHub WebHooks For Node, which can filter the payloads by payload type: repository, branch, file or tag

You have simpler listeners, for instance on in python.
Again, the specifics of the listener and what you can do when you receive the message (like a git pull to download what has changed) depend on your particular environment.

Community
  • 1
  • 1
VonC
  • 1,262,500
  • 529
  • 4,410
  • 5,250