Documentation
¶
Index ¶
- type Client
- func (gh *Client) AddComment(comment string) error
- func (gh *Client) AllApprovals() ([]*CurrentApproval, error)
- func (gh *Client) ApprovePR() error
- func (gh *Client) CheckApprovals(fileReviewerMap map[string][]string, approvals []*CurrentApproval, ...) (approvers []string, staleApprovals []*CurrentApproval)
- func (gh *Client) DismissStaleReviews(staleApprovals []*CurrentApproval) error
- func (gh *Client) FindUserApproval(ghUser string) (*CurrentApproval, error)
- func (gh *Client) GetAlreadyReviewed() ([]string, error)
- func (gh *Client) GetCurrentReviewerApprovals() ([]*CurrentApproval, error)
- func (gh *Client) GetCurrentlyRequested() ([]string, error)
- func (gh *Client) GetTokenUser() (string, error)
- func (gh *Client) InitComments() error
- func (gh *Client) InitPR(pr_id int) error
- func (gh *Client) InitReviews() error
- func (gh *Client) InitUserReviewerMap(reviewers []string) error
- func (gh *Client) IsInComments(comment string, since *time.Time) (bool, error)
- func (gh *Client) IsSubstringInComments(substring string, since *time.Time) (bool, error)
- func (gh *Client) RequestReviewers(reviewers []string) error
- func (gh *Client) SetInfoBuffer(writer io.Writer)
- func (gh *Client) SetWarningBuffer(writer io.Writer)
- type CurrentApproval
- type NoPRError
- type UserReviewerMapNotInitError
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Client ¶
type Client struct {
PR *github.PullRequest
// contains filtered or unexported fields
}
func (*Client) AddComment ¶
func (*Client) AllApprovals ¶
func (gh *Client) AllApprovals() ([]*CurrentApproval, error)
func (*Client) CheckApprovals ¶
func (gh *Client) CheckApprovals( fileReviewerMap map[string][]string, approvals []*CurrentApproval, originalDiff git.Diff, ) (approvers []string, staleApprovals []*CurrentApproval)
Apply approver satisfaction to the owners map, and return the approvals which should be invalidated
func (*Client) DismissStaleReviews ¶
func (gh *Client) DismissStaleReviews(staleApprovals []*CurrentApproval) error
func (*Client) FindUserApproval ¶
func (gh *Client) FindUserApproval(ghUser string) (*CurrentApproval, error)
func (*Client) GetAlreadyReviewed ¶
func (*Client) GetCurrentReviewerApprovals ¶
func (gh *Client) GetCurrentReviewerApprovals() ([]*CurrentApproval, error)
func (*Client) GetCurrentlyRequested ¶
func (*Client) GetTokenUser ¶
func (*Client) InitComments ¶
func (*Client) InitReviews ¶
func (*Client) InitUserReviewerMap ¶
func (*Client) IsInComments ¶
func (*Client) IsSubstringInComments ¶
func (*Client) RequestReviewers ¶
func (*Client) SetInfoBuffer ¶
func (*Client) SetWarningBuffer ¶
type CurrentApproval ¶
func (*CurrentApproval) String ¶
func (p *CurrentApproval) String() string
type UserReviewerMapNotInitError ¶
type UserReviewerMapNotInitError struct{}
func (UserReviewerMapNotInitError) Error ¶
func (e UserReviewerMapNotInitError) Error() string
Click to show internal directories.
Click to hide internal directories.