cherry

package
v1.0.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 28, 2020 License: Apache-2.0 Imports: 17 Imported by: 0

Documentation

Index

Constants

View Source
const (
	LOAD_COLLABORATOR_DURATION  = 10 * time.Minute
	PENDING_INVITATION_COOLDOWN = 10 * time.Minute
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Cherry

type Cherry interface {
	Ready()
	ProcessPullRequest(pr *github.PullRequest)
	ProcessPullRequestEvent(event *github.PullRequestEvent)
	ProcessIssueCommentEvent(event *github.IssueCommentEvent)
	MonthCheck(pr *github.PullRequest) ([]string, error)
}

Cherry defines methods of cherry pick

func Init

func Init(repo *config.RepoConfig, opr *operator.Operator) Cherry

Init create cherry pick middleware instance

type CherryPr

type CherryPr struct {
	ID           int    `gorm:"column:id"`
	PrID         int    `gorm:"column:pull_number"`
	FromPr       int    `gorm:"column:from_pull_number"`
	Owner        string `gorm:"column:owner"`
	Repo         string `gorm:"column:repo"`
	Title        string `gorm:"column:title"`
	Head         string `gorm:"column:head"`
	Base         string `gorm:"column:base"`
	Body         string `gorm:"column:body"`
	CreatedByBot bool   `gorm:"column:created_by_bot"`
	TryTime      int    `gorm:"column:try_time"`
	Success      bool   `gorm:"column:success"`
}

CherryPr is cherry pick table structure

type SlackUser

type SlackUser struct {
	ID     int    `gorm:"id"`
	Github string `gorm:"github"`
	Email  string `gorm:"email"`
	Slack  string `gorm:"slack"`
}

SlackUser is slack user table structure

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL