Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Reporter ¶
type Reporter struct { // ReportDay representing which is the weekly report generation day. ReportDay string // ReportHour representing which is the weekly report generation time on ReportDay. ReportHour int // contains filtered or unexported fields }
Reporter is a reporter to report weekly update on Github Repo in issues. Reports needs to use the repo name to construct the weeklyreport name. Since weekly report generation should be general to all kinds of open source project.
func (*Reporter) CalculateReviews ¶
func (r *Reporter) CalculateReviews(wr *WeekReport)
CalculateReviews calculates reviews from user since the last week.
type StatsLastWeek ¶
StatsLastWeek collects repo data from last week.
type WeekReport ¶
type WeekReport struct { // time of this weekly report's start time. StartDate string // time of this weekly report's end time. EndDate string // Watch defines currently how many github users are watching this repo. Watch int // Star defines currently how many github users are staring this repo. Star int // Fork defines currently how many github users have forked this repo. Fork int // Contributors defines the number of contributors. Contributors int // NumOfNewIssues is the issues number which are created in the last week. NumOfNewIssues int // NumOfClosedIssues is the issues number which are closed in the last week. NumOfClosedIssues int // MergedPR defines how many pull requests have beem merge between time StartDate and EndDate. MergedPR map[string][]*SimplePR // CountOfPR defines the number of merged pull request. CountOfPR int // NewContributors defines new contributors between time StartDate and EndDate. NewContributors []string // PRReviewsByUser defines that all pull request reviews submitted between time StartDate and EndDate. // PRReviewsByUser has a type map, the key is User, Value is the number of pull reuqest reviews of single User. PRReviewsByUser map[string]int // contains filtered or unexported fields }
WeekReport contains details about elements to construct a report.
func (*WeekReport) String ¶
func (wr *WeekReport) String() string
String returns a string of Week Report
Click to show internal directories.
Click to hide internal directories.