Show More
@@ -129,6 +129,9 b' if __name__ == "__main__":' | |||||
129 | parser.add_argument('--days', type=int, |
|
129 | parser.add_argument('--days', type=int, | |
130 | help="The number of days of data to summarize (use this or --since-tag)." |
|
130 | help="The number of days of data to summarize (use this or --since-tag)." | |
131 | ) |
|
131 | ) | |
|
132 | parser.add_argument('--project', type=str, default="ipython/ipython", | |||
|
133 | help="The project to summarize." | |||
|
134 | ) | |||
132 |
|
135 | |||
133 | opts = parser.parse_args() |
|
136 | opts = parser.parse_args() | |
134 | tag = opts.since_tag |
|
137 | tag = opts.since_tag | |
@@ -153,19 +156,20 b' if __name__ == "__main__":' | |||||
153 | since = round_hour(since) |
|
156 | since = round_hour(since) | |
154 |
|
157 | |||
155 | milestone = opts.milestone |
|
158 | milestone = opts.milestone | |
|
159 | project = opts.project | |||
156 |
|
160 | |||
157 | print("fetching GitHub stats since %s (tag: %s, milestone: %s)" % (since, tag, milestone), file=sys.stderr) |
|
161 | print("fetching GitHub stats since %s (tag: %s, milestone: %s)" % (since, tag, milestone), file=sys.stderr) | |
158 | if milestone: |
|
162 | if milestone: | |
159 |
milestone_id = get_milestone_id( |
|
163 | milestone_id = get_milestone_id(project=project, milestone=milestone, | |
160 | auth=True) |
|
164 | auth=True) | |
161 |
issues = get_issues_list( |
|
165 | issues = get_issues_list(project=project, | |
162 | milestone=milestone_id, |
|
166 | milestone=milestone_id, | |
163 | state='closed', |
|
167 | state='closed', | |
164 | auth=True, |
|
168 | auth=True, | |
165 | ) |
|
169 | ) | |
166 | else: |
|
170 | else: | |
167 | issues = issues_closed_since(since, pulls=False) |
|
171 | issues = issues_closed_since(since, project=project, pulls=False) | |
168 | pulls = issues_closed_since(since, pulls=True) |
|
172 | pulls = issues_closed_since(since, project=project, pulls=True) | |
169 |
|
173 | |||
170 | # For regular reports, it's nice to show them in reverse chronological order |
|
174 | # For regular reports, it's nice to show them in reverse chronological order | |
171 | issues = sorted_by_field(issues, reverse=True) |
|
175 | issues = sorted_by_field(issues, reverse=True) |
General Comments 0
You need to be logged in to leave comments.
Login now