On 11/06/2015 08:05 AM, Ezio Zhang wrote: > thanks. but I have a question that : > > |GET /projects/:id/repository/commits| > > how can I use GET in shell? I tried install GET with apt,but I don't > know where to use it. > Or these API are via web? >
These are API method calls and you can use curl. For example: curl -H "PRIVATE-TOKEN: t0k3n" https://gitlab.com/api/v3/projects/403626/repository/commits | json_pp 403626 is the id of the project. A list of your projects can be found with: curl -H "PRIVATE-TOKEN: t0k3n" https://gitlab.com/api/v3/projects | json_pp Then look for the id you are interested in. Of course, change gitlab.com with the url of your instance if you are using your own. Your private token can be found under /profile/account. json_pp is a tool provided by perl and has a nicer JSON output combined with curl. It is optional. Actually I'm working on improving the API docs with curl examples for every call. This is a work in progress, see https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/681 In your case https://gitlab.com/gitlab-org/gitlab-ce/blob/fedfa53599ceb184bc9d26284b3cf589cff73dae/doc/api/commits.md -- Blog: http://axilleas.me -- You received this message because you are subscribed to the Google Groups "GitLab" group. To unsubscribe from this group and stop receiving emails from it, send an email to gitlabhq+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/gitlabhq/563C4CD8.8060209%40gmail.com. For more options, visit https://groups.google.com/d/optout.