-
-
Notifications
You must be signed in to change notification settings - Fork 3.1k
Report new contributors project
Josh Matthews edited this page Feb 16, 2017
·
4 revisions
Background information: For the weekly This Week in Servo blog post, we list the new contributors to the servo/servo repository. We want to be able to track this information across all repositories in the servo organization. The goal of this work is to build a system that uses the Github API to determine this information on a regular basis.
Tracking issue: https://github.com/servo/servo/issues/15601 (please ask questions here)
Initial steps:
- email the mozilla.dev.servo mailing list (be sure to subscribe to it first!) introducing your group and asking any necessary questions
- create a github organization with several repositories that can be used for manual tests
- create a tool that initializes a JSON file with the known authors for a local git repository
- create a tool that clones every git repository in a given github organization (use the github API to retrieve this information)
Subsequent steps:
- make the initialization tool support stopping at a particular date or commit
- create a tool that processes all of the closed pull requests for a github organization during a particular time period
- Via the github API:
curl -i "https://api.github.com/orgs/[organization]/issues?filter=all&state=closed&sort=updated&since=2017-02-05T00:00:00Z" -u [user]:[token]
(token may require private repo permissions) - for each pull request, get the list of commits present
- for each commit, get the author/committer present
- if the author is not known, add it to the list of new contributors
- return the list of new contributors with names and links to github profiles
- update the JSON file containing known authors
- Via the github API:
- create unit tests mocking the github API usage validating the behaviour of the tool