I am hoping to gather some aggregated statistics relating to which user(s) have contributed various commits to any given branch, and which users have reviewed any given pull request.
On the command line, I can use "git log" to retrieve a list of commits to any given branch (such as develop/ which is the branch I am interested in). I can iterate this command line output and retrieve the commit hash, and the username / email who made the commit.
After that, I can then use the Bitbucket website to view each pull request, but it's a manual process. Is there a git command that lists all pull requests similar to that found on the website under https://...../repos/...../pull-requests/ ?
Thank you very much for any assistance!
Hi @David Cash
Sorry for the late response.
Unfortunately, there isn't a git command to perform exactly what you are looking for.
However, it is possible to use bitbucket rest API to retrieve information about the pull request.
Pull request API:
https://developer.atlassian.com/bitbucket/api/2/reference/resource/repositories/%7Busername%7D/%7Brepo_slug%7D/pullrequests#get
Querying pull requests:
https://developer.atlassian.com/bitbucket/api/2/reference/meta/filtering#query-pullreq
Authentication methods:
https://developer.atlassian.com/bitbucket/api/2/reference/meta/authentication
Please, do not hesitate to ask if you need any further assistance.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.