Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Retrieve private repository commits from github

I need to retrieve all commits from Private repositories on github.

I already tried with with github API documentation. It provides the API for retrieving the public repository commits. https://api.github.com/repos/:owner/:repo/commits

Anybody can help me for taking all commits from private repositories?

like image 498
Anoop Avatar asked Nov 07 '12 20:11

Anoop


1 Answers

A private repository means you need to authenticate in order to execute your query (here getting the commits).
This should work, if you own the private repo:

curl -u 'username:password' https://api.github.com/repos/:owner/:repo/commits
like image 70
VonC Avatar answered Sep 21 '22 22:09

VonC