Documentation
¶
Index ¶
- Constants
- Variables
- func ClonePR(ctx context.Context, root string, pr review.QueuedPR) (string, error)
- func ConfiguredRepoNames(cfg *config.Config) map[string]bool
- func FetchLocalCommitsBetween(ctx context.Context, cfg *config.Config, since, until time.Time) map[string][]PRItem
- func FetchLocalCommitsForDays(ctx context.Context, cfg *config.Config, dates ...time.Time) []map[string][]PRItem
- func FilterQueuedPRs(prs []review.QueuedPR, allowed map[string]bool) []review.QueuedPR
- func FilterReviewRecords(reviews []review.ActivityPR, allowed map[string]bool) []review.ActivityPR
- func RepoNameAllowed(repository string, allowed map[string]bool) bool
- func RepoScopes(cfg *config.Config) map[string][]string
- func ReviewRecord(pr review.QueuedPR, state string, reviewedAt time.Time) review.ActivityPR
- func SortItems(items []PRItem, activeSort Sort)
- func Sync(ctx context.Context, params SyncParams) <-chan Section
- type Day
- type DayResult
- type Engine
- func (e *Engine) AuthoredPRs(ctx context.Context, start, end time.Time) ([]review.QueuedPR, []review.QueuedPR, error)
- func (e *Engine) FetchDay(ctx context.Context, day Day, date time.Time) DayResult
- func (e *Engine) FetchMyPRs(ctx context.Context, known []review.PRRef) MyPRsResult
- func (e *Engine) FetchPendingPRs(ctx context.Context, activeSort Sort) PendingResult
- type MyPRsResult
- type PRItem
- type PendingResult
- type Section
- type Sort
- type SyncParams
Constants ¶
View Source
const ( PendingReviewKind = "Pending Review" ReReviewKind = "Re-review" ReviewedKind = "Reviewed" CommitKind = "Commit" )
View Source
const SectionCount = 4
Variables ¶
View Source
var ErrCloneInProgress = errors.New("the running review is still cloning; try again shortly")
Functions ¶
func FilterQueuedPRs ¶
func FilterReviewRecords ¶
func FilterReviewRecords(reviews []review.ActivityPR, allowed map[string]bool) []review.ActivityPR
func ReviewRecord ¶
Types ¶
type DayResult ¶
type DayResult struct {
Day Day
Date string
Reviewed []PRItem
Reviews []review.ActivityPR
Details map[string]json.RawMessage
FailedHosts []string
Err error
}
type Engine ¶
type Engine struct {
// contains filtered or unexported fields
}
func (*Engine) AuthoredPRs ¶
func (*Engine) FetchMyPRs ¶
func (*Engine) FetchPendingPRs ¶
func (e *Engine) FetchPendingPRs(ctx context.Context, activeSort Sort) PendingResult
type MyPRsResult ¶
type PRItem ¶
type PendingResult ¶
type Section ¶
type Section struct {
Day *DayResult
Pending *PendingResult
MyPRs *MyPRsResult
}
Click to show internal directories.
Click to hide internal directories.