Documentation ¶
Overview ¶
Package mungers deals with munging of github pull requests
Index ¶
- func EachLoop() error
- func InitializeMungers(config *github.Config, features *features.Features) error
- func MungeIssue(obj *github.MungeObject) error
- func RegisterMunger(munger Munger) error
- func RegisterMungerOrDie(munger Munger)
- func RegisterMungers(requestedMungers []string) error
- func RegisterStaleComments(s StaleComment)
- func RequestedFeatures() []string
- type AssignFixesMunger
- func (a *AssignFixesMunger) AddFlags(cmd *cobra.Command, config *github.Config)
- func (a *AssignFixesMunger) EachLoop() error
- func (a *AssignFixesMunger) Initialize(config *github.Config, features *features.Features) error
- func (a *AssignFixesMunger) Munge(obj *github.MungeObject)
- func (a *AssignFixesMunger) Name() string
- func (a *AssignFixesMunger) RequiredFeatures() []string
- type BlockPath
- func (b *BlockPath) AddFlags(cmd *cobra.Command, config *github.Config)
- func (b *BlockPath) EachLoop() error
- func (b *BlockPath) Initialize(config *github.Config, features *features.Features) error
- func (b *BlockPath) Munge(obj *github.MungeObject)
- func (b *BlockPath) Name() string
- func (b *BlockPath) RequiredFeatures() []string
- func (b *BlockPath) StaleComments(obj *github.MungeObject, comments []*githubapi.IssueComment) []*githubapi.IssueComment
- type BlunderbussConfig
- type BlunderbussMunger
- func (b *BlunderbussMunger) AddFlags(cmd *cobra.Command, config *github.Config)
- func (b *BlunderbussMunger) EachLoop() error
- func (b *BlunderbussMunger) Initialize(config *github.Config, features *features.Features) error
- func (b *BlunderbussMunger) Munge(obj *github.MungeObject)
- func (b *BlunderbussMunger) Name() string
- func (b *BlunderbussMunger) RequiredFeatures() []string
- type CheckLabelsMunger
- func (c *CheckLabelsMunger) AddFlags(cmd *cobra.Command, config *githubhelper.Config)
- func (c *CheckLabelsMunger) EachLoop() error
- func (c *CheckLabelsMunger) Initialize(config *githubhelper.Config, features *features.Features) error
- func (c *CheckLabelsMunger) Munge(obj *githubhelper.MungeObject)
- func (c *CheckLabelsMunger) Name() string
- func (c *CheckLabelsMunger) RequiredFeatures() []string
- type CherrypickAutoApprove
- func (c *CherrypickAutoApprove) AddFlags(cmd *cobra.Command, config *github.Config)
- func (c *CherrypickAutoApprove) EachLoop() error
- func (c *CherrypickAutoApprove) Initialize(config *github.Config, features *features.Features) error
- func (c *CherrypickAutoApprove) Munge(obj *github.MungeObject)
- func (c *CherrypickAutoApprove) Name() string
- func (c *CherrypickAutoApprove) RequiredFeatures() []string
- type CherrypickQueue
- func (c *CherrypickQueue) AddFlags(cmd *cobra.Command, config *github.Config)
- func (c *CherrypickQueue) EachLoop() error
- func (c *CherrypickQueue) Initialize(config *github.Config, features *features.Features) error
- func (c *CherrypickQueue) Munge(obj *github.MungeObject)
- func (c *CherrypickQueue) Name() string
- func (c *CherrypickQueue) RequiredFeatures() []string
- type ClaMunger
- func (c *ClaMunger) AddFlags(cmd *cobra.Command, config *githubhelper.Config)
- func (c *ClaMunger) EachLoop() error
- func (c *ClaMunger) Initialize(config *githubhelper.Config, features *features.Features) error
- func (c *ClaMunger) Munge(obj *githubhelper.MungeObject)
- func (c *ClaMunger) Name() string
- func (c *ClaMunger) RequiredFeatures() []string
- type ClearPickAfterMerge
- func (c *ClearPickAfterMerge) AddFlags(cmd *cobra.Command, config *github.Config)
- func (c *ClearPickAfterMerge) EachLoop() error
- func (c *ClearPickAfterMerge) Initialize(config *github.Config, features *features.Features) error
- func (c *ClearPickAfterMerge) Munge(obj *github.MungeObject)
- func (c *ClearPickAfterMerge) Name() string
- func (c *ClearPickAfterMerge) RequiredFeatures() []string
- type CloseStalePR
- func (CloseStalePR) AddFlags(cmd *cobra.Command, config *github.Config)
- func (CloseStalePR) EachLoop() error
- func (CloseStalePR) Initialize(config *github.Config, features *features.Features) error
- func (CloseStalePR) Munge(obj *github.MungeObject)
- func (CloseStalePR) Name() string
- func (CloseStalePR) RequiredFeatures() []string
- func (s CloseStalePR) StaleComments(obj *github.MungeObject, comments []*githubapi.IssueComment) []*githubapi.IssueComment
- type CommentDeleter
- func (CommentDeleter) AddFlags(cmd *cobra.Command, config *github.Config)
- func (CommentDeleter) EachLoop() error
- func (CommentDeleter) Initialize(config *github.Config, features *features.Features) error
- func (CommentDeleter) Munge(obj *github.MungeObject)
- func (CommentDeleter) Name() string
- func (CommentDeleter) RequiredFeatures() []string
- type CommentDeleterJenkins
- type DocsNeedNoRetest
- func (DocsNeedNoRetest) AddFlags(cmd *cobra.Command, config *github.Config)
- func (DocsNeedNoRetest) EachLoop() error
- func (s *DocsNeedNoRetest) Initialize(config *github.Config, features *features.Features) error
- func (DocsNeedNoRetest) Munge(obj *github.MungeObject)
- func (DocsNeedNoRetest) Name() string
- func (DocsNeedNoRetest) RequiredFeatures() []string
- type FlakeManager
- func (p *FlakeManager) AddFlags(cmd *cobra.Command, config *github.Config)
- func (p *FlakeManager) EachLoop() error
- func (p *FlakeManager) Initialize(config *github.Config, features *features.Features) error
- func (p *FlakeManager) Munge(obj *github.MungeObject)
- func (p *FlakeManager) Name() string
- func (p *FlakeManager) RequiredFeatures() []string
- type IssueCacher
- func (p *IssueCacher) AddFlags(cmd *cobra.Command, config *github.Config)
- func (p *IssueCacher) AllIssuesForKey(key string) []int
- func (p *IssueCacher) Created(key string, number int)
- func (p *IssueCacher) EachLoop() error
- func (p *IssueCacher) Initialize(config *github.Config, features *features.Features) error
- func (p *IssueCacher) Munge(obj *github.MungeObject)
- func (p *IssueCacher) Name() string
- func (p *IssueCacher) RequiredFeatures() []string
- func (p *IssueCacher) Synced() bool
- type LGTMAfterCommitMunger
- func (LGTMAfterCommitMunger) AddFlags(cmd *cobra.Command, config *github.Config)
- func (LGTMAfterCommitMunger) EachLoop() error
- func (LGTMAfterCommitMunger) Initialize(config *github.Config, features *features.Features) error
- func (LGTMAfterCommitMunger) Munge(obj *github.MungeObject)
- func (LGTMAfterCommitMunger) Name() string
- func (LGTMAfterCommitMunger) RequiredFeatures() []string
- func (l LGTMAfterCommitMunger) StaleComments(obj *github.MungeObject, comments []*githubapi.IssueComment) []*githubapi.IssueComment
- type LGTMHandler
- func (LGTMHandler) AddFlags(cmd *cobra.Command, config *github.Config)
- func (LGTMHandler) EachLoop() error
- func (LGTMHandler) Initialize(config *github.Config, features *features.Features) error
- func (h LGTMHandler) Munge(obj *github.MungeObject)
- func (LGTMHandler) Name() string
- func (LGTMHandler) RequiredFeatures() []string
- type LabelMunger
- func (lm *LabelMunger) AddFlags(cmd *cobra.Command, config *github.Config)
- func (LabelMunger) EachLoop() error
- func (LabelMunger) Initialize(config *github.Config, features *features.Features) error
- func (lm *LabelMunger) Munge(obj *github.MungeObject)
- func (LabelMunger) Name() string
- func (LabelMunger) RequiredFeatures() []string
- type LabelUnapprovedPicks
- func (LabelUnapprovedPicks) AddFlags(cmd *cobra.Command, config *github.Config)
- func (LabelUnapprovedPicks) EachLoop() error
- func (LabelUnapprovedPicks) Initialize(config *github.Config, features *features.Features) error
- func (LabelUnapprovedPicks) Munge(obj *github.MungeObject)
- func (LabelUnapprovedPicks) Name() string
- func (LabelUnapprovedPicks) RequiredFeatures() []string
- func (l LabelUnapprovedPicks) StaleComments(obj *github.MungeObject, comments []*githubapi.IssueComment) []*githubapi.IssueComment
- type Munger
- type NagFlakeIssues
- func (NagFlakeIssues) AddFlags(cmd *cobra.Command, config *mgh.Config)
- func (NagFlakeIssues) EachLoop() error
- func (NagFlakeIssues) Initialize(config *mgh.Config, features *features.Features) error
- func (NagFlakeIssues) Munge(obj *mgh.MungeObject)
- func (NagFlakeIssues) Name() string
- func (NagFlakeIssues) RequiredFeatures() []string
- func (NagFlakeIssues) StaleComments(obj *mgh.MungeObject, comments []*github.IssueComment) []*github.IssueComment
- type NeedsRebaseMunger
- func (NeedsRebaseMunger) AddFlags(cmd *cobra.Command, config *github.Config)
- func (NeedsRebaseMunger) EachLoop() error
- func (NeedsRebaseMunger) Initialize(config *github.Config, features *features.Features) error
- func (NeedsRebaseMunger) Munge(obj *github.MungeObject)
- func (NeedsRebaseMunger) Name() string
- func (NeedsRebaseMunger) RequiredFeatures() []string
- func (n NeedsRebaseMunger) StaleComments(obj *github.MungeObject, comments []*githubapi.IssueComment) []*githubapi.IssueComment
- type OkToTestMunger
- func (ok *OkToTestMunger) AddFlags(cmd *cobra.Command, config *github.Config)
- func (ok *OkToTestMunger) EachLoop() error
- func (ok *OkToTestMunger) Initialize(config *github.Config, features *features.Features) error
- func (ok *OkToTestMunger) Munge(obj *github.MungeObject)
- func (ok *OkToTestMunger) Name() string
- func (ok *OkToTestMunger) RequiredFeatures() []string
- func (ok *OkToTestMunger) StaleComments(obj *github.MungeObject, comments []*githubapi.IssueComment) []*githubapi.IssueComment
- type OldTestGetter
- func (p *OldTestGetter) AddFlags(cmd *cobra.Command, config *github.Config)
- func (p *OldTestGetter) EachLoop() error
- func (p *OldTestGetter) Initialize(config *github.Config, features *features.Features) error
- func (p *OldTestGetter) Munge(obj *github.MungeObject)
- func (p *OldTestGetter) Name() string
- func (p *OldTestGetter) RequiredFeatures() []string
- type PathLabelMunger
- func (p *PathLabelMunger) AddFlags(cmd *cobra.Command, config *github.Config)
- func (p *PathLabelMunger) EachLoop() error
- func (p *PathLabelMunger) Initialize(config *github.Config, features *features.Features) error
- func (p *PathLabelMunger) Munge(obj *github.MungeObject)
- func (p *PathLabelMunger) Name() string
- func (p *PathLabelMunger) RequiredFeatures() []string
- type PickMustHaveMilestone
- func (PickMustHaveMilestone) AddFlags(cmd *cobra.Command, config *github.Config)
- func (PickMustHaveMilestone) EachLoop() error
- func (PickMustHaveMilestone) Initialize(config *github.Config, features *features.Features) error
- func (PickMustHaveMilestone) Munge(obj *github.MungeObject)
- func (PickMustHaveMilestone) Name() string
- func (PickMustHaveMilestone) RequiredFeatures() []string
- func (p PickMustHaveMilestone) StaleComments(obj *github.MungeObject, comments []*githubapi.IssueComment) []*githubapi.IssueComment
- type PublisherMunger
- func (p *PublisherMunger) AddFlags(cmd *cobra.Command, config *github.Config)
- func (p *PublisherMunger) EachLoop() error
- func (p *PublisherMunger) Initialize(config *github.Config, features *features.Features) error
- func (p *PublisherMunger) Munge(obj *github.MungeObject)
- func (p *PublisherMunger) Name() string
- func (p *PublisherMunger) RequiredFeatures() []string
- type RebuildMunger
- func (r *RebuildMunger) AddFlags(cmd *cobra.Command, config *github.Config)
- func (r *RebuildMunger) EachLoop() error
- func (r *RebuildMunger) Initialize(config *github.Config, features *features.Features) error
- func (r *RebuildMunger) Munge(obj *github.MungeObject)
- func (r *RebuildMunger) Name() string
- func (r *RebuildMunger) RequiredFeatures() []string
- func (r *RebuildMunger) StaleComments(obj *github.MungeObject, comments []*githubapi.IssueComment) []*githubapi.IssueComment
- type ReleaseNoteLabel
- func (r *ReleaseNoteLabel) AddFlags(cmd *cobra.Command, config *github.Config)
- func (r *ReleaseNoteLabel) EachLoop() error
- func (r *ReleaseNoteLabel) Initialize(config *github.Config, features *features.Features) error
- func (r *ReleaseNoteLabel) Munge(obj *github.MungeObject)
- func (r *ReleaseNoteLabel) Name() string
- func (r *ReleaseNoteLabel) RequiredFeatures() []string
- func (r *ReleaseNoteLabel) StaleComments(obj *github.MungeObject, comments []*githubapi.IssueComment) []*githubapi.IssueComment
- type SizeMunger
- func (s *SizeMunger) AddFlags(cmd *cobra.Command, config *github.Config)
- func (SizeMunger) EachLoop() error
- func (s *SizeMunger) Initialize(config *github.Config, features *features.Features) error
- func (s *SizeMunger) Munge(obj *github.MungeObject)
- func (SizeMunger) Name() string
- func (SizeMunger) RequiredFeatures() []string
- func (s *SizeMunger) StaleComments(obj *github.MungeObject, comments []*githubapi.IssueComment) []*githubapi.IssueComment
- type StaleComment
- type StaleGreenCI
- func (s *StaleGreenCI) AddFlags(cmd *cobra.Command, config *github.Config)
- func (s *StaleGreenCI) EachLoop() error
- func (s *StaleGreenCI) Initialize(config *github.Config, features *features.Features) error
- func (s *StaleGreenCI) Munge(obj *github.MungeObject)
- func (s *StaleGreenCI) Name() string
- func (s *StaleGreenCI) RequiredFeatures() []string
- func (s *StaleGreenCI) StaleComments(obj *github.MungeObject, comments []*githubapi.IssueComment) []*githubapi.IssueComment
- type StalePendingCI
- func (s *StalePendingCI) AddFlags(cmd *cobra.Command, config *github.Config)
- func (s *StalePendingCI) EachLoop() error
- func (s *StalePendingCI) Initialize(config *github.Config, features *features.Features) error
- func (s *StalePendingCI) Munge(obj *github.MungeObject)
- func (s *StalePendingCI) Name() string
- func (s *StalePendingCI) RequiredFeatures() []string
- func (s *StalePendingCI) StaleComments(obj *github.MungeObject, comments []*githubapi.IssueComment) []*githubapi.IssueComment
- type SubmitQueue
- func (sq *SubmitQueue) AddFlags(cmd *cobra.Command, config *github.Config)
- func (sq *SubmitQueue) EachLoop() error
- func (sq *SubmitQueue) EmergencyStopHTTP(res http.ResponseWriter, req *http.Request)
- func (sq *SubmitQueue) Initialize(config *github.Config, features *features.Features) error
- func (sq *SubmitQueue) Munge(obj *github.MungeObject)
- func (sq *SubmitQueue) Name() string
- func (sq *SubmitQueue) RequiredFeatures() []string
- func (sq *SubmitQueue) SetMergeStatus(obj *github.MungeObject, reason string)
- func (sq *SubmitQueue) StaleComments(obj *github.MungeObject, comments []*githubapi.IssueComment) []*githubapi.IssueComment
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func EachLoop ¶
func EachLoop() error
EachLoop will be called before we start a poll loop and will run the EachLoop function for all active mungers
func InitializeMungers ¶
InitializeMungers will call munger.Initialize() for the requested mungers.
func MungeIssue ¶
func MungeIssue(obj *github.MungeObject) error
MungeIssue will call each activated munger with the given object
func RegisterMunger ¶
RegisterMunger should be called in `init()` by each munger to make itself available by name
func RegisterMungerOrDie ¶
func RegisterMungerOrDie(munger Munger)
RegisterMungerOrDie will call RegisterMunger but will be fatal on error
func RegisterMungers ¶
RegisterMungers will check if a requested munger exists and add it to the list.
func RegisterStaleComments ¶
func RegisterStaleComments(s StaleComment)
RegisterStaleComments is the method for a munger to register that it creates comment which might go stale and need to be cleaned up
func RequestedFeatures ¶
func RequestedFeatures() []string
RequestedFeatures returns a list of all feature which should be enabled for the running mungers
Types ¶
type AssignFixesMunger ¶
type AssignFixesMunger struct { AssignfixesReassign bool // contains filtered or unexported fields }
AssignFixesMunger will assign issues to users based on the config file provided by --assignfixes-config.
func (*AssignFixesMunger) AddFlags ¶
func (a *AssignFixesMunger) AddFlags(cmd *cobra.Command, config *github.Config)
AddFlags will add any request flags to the cobra `cmd`
func (*AssignFixesMunger) EachLoop ¶
func (a *AssignFixesMunger) EachLoop() error
EachLoop is called at the start of every munge loop
func (*AssignFixesMunger) Initialize ¶
Initialize will initialize the munger
func (*AssignFixesMunger) Munge ¶
func (a *AssignFixesMunger) Munge(obj *github.MungeObject)
Munge is the workhorse the will actually make updates to the PR
func (*AssignFixesMunger) Name ¶
func (a *AssignFixesMunger) Name() string
Name is the name usable in --pr-mungers
func (*AssignFixesMunger) RequiredFeatures ¶
func (a *AssignFixesMunger) RequiredFeatures() []string
RequiredFeatures is a slice of 'features' that must be provided
type BlockPath ¶
type BlockPath struct { Path string // contains filtered or unexported fields }
BlockPath will add a label to block auto merge if a PR touches certain paths
func (*BlockPath) Initialize ¶
Initialize will initialize the munger
func (*BlockPath) Munge ¶
func (b *BlockPath) Munge(obj *github.MungeObject)
Munge is the workhorse the will actually make updates to the PR
func (*BlockPath) RequiredFeatures ¶
RequiredFeatures is a slice of 'features' that must be provided
func (*BlockPath) StaleComments ¶
func (b *BlockPath) StaleComments(obj *github.MungeObject, comments []*githubapi.IssueComment) []*githubapi.IssueComment
StaleComments returns a slice of stale comments
type BlunderbussConfig ¶
type BlunderbussConfig struct {
PrefixMap map[string][]string `json:"prefixMap,omitempty" yaml:"prefixMap,omitempty"`
}
A BlunderbussConfig maps a set of file prefixes to a set of owner names (github users)
type BlunderbussMunger ¶
type BlunderbussMunger struct { BlunderbussReassign bool // contains filtered or unexported fields }
BlunderbussMunger will assign issues to users based on the config file provided by --blunderbuss-config.
func (*BlunderbussMunger) AddFlags ¶
func (b *BlunderbussMunger) AddFlags(cmd *cobra.Command, config *github.Config)
AddFlags will add any request flags to the cobra `cmd`
func (*BlunderbussMunger) EachLoop ¶
func (b *BlunderbussMunger) EachLoop() error
EachLoop is called at the start of every munge loop
func (*BlunderbussMunger) Initialize ¶
Initialize will initialize the munger
func (*BlunderbussMunger) Munge ¶
func (b *BlunderbussMunger) Munge(obj *github.MungeObject)
Munge is the workhorse the will actually make updates to the PR
func (*BlunderbussMunger) Name ¶
func (b *BlunderbussMunger) Name() string
Name is the name usable in --pr-mungers
func (*BlunderbussMunger) RequiredFeatures ¶
func (b *BlunderbussMunger) RequiredFeatures() []string
RequiredFeatures is a slice of 'features' that must be provided
type CheckLabelsMunger ¶
type CheckLabelsMunger struct { LabelFilePath string // contains filtered or unexported fields }
CheckLabelsMunger will check that the labels specified in the labels yaml file are created.
func (*CheckLabelsMunger) AddFlags ¶
func (c *CheckLabelsMunger) AddFlags(cmd *cobra.Command, config *githubhelper.Config)
AddFlags will add any request flags to the cobra `cmd`.
func (*CheckLabelsMunger) EachLoop ¶
func (c *CheckLabelsMunger) EachLoop() error
EachLoop is called at the start of every munge loop
func (*CheckLabelsMunger) Initialize ¶
func (c *CheckLabelsMunger) Initialize(config *githubhelper.Config, features *features.Features) error
Initialize will initialize the munger.
func (*CheckLabelsMunger) Munge ¶
func (c *CheckLabelsMunger) Munge(obj *githubhelper.MungeObject)
Munge is unused by this munger.
func (*CheckLabelsMunger) Name ¶
func (c *CheckLabelsMunger) Name() string
Name is the name usable in --pr-mungers
func (*CheckLabelsMunger) RequiredFeatures ¶
func (c *CheckLabelsMunger) RequiredFeatures() []string
RequiredFeatures is a slice of 'features' that must be provided.
type CherrypickAutoApprove ¶
type CherrypickAutoApprove struct {
// contains filtered or unexported fields
}
CherrypickAutoApprove will add 'cherrypick-approved' to PRs which are for 'cherrypick-approved' parents. This only works if the PR (against the 'release-*' branch was done using the script.
func (*CherrypickAutoApprove) AddFlags ¶
func (c *CherrypickAutoApprove) AddFlags(cmd *cobra.Command, config *github.Config)
AddFlags will add any request flags to the cobra `cmd`
func (*CherrypickAutoApprove) EachLoop ¶
func (c *CherrypickAutoApprove) EachLoop() error
EachLoop is called at the start of every munge loop
func (*CherrypickAutoApprove) Initialize ¶
func (c *CherrypickAutoApprove) Initialize(config *github.Config, features *features.Features) error
Initialize will initialize the munger
func (*CherrypickAutoApprove) Munge ¶
func (c *CherrypickAutoApprove) Munge(obj *github.MungeObject)
Munge is the workhorse the will actually make updates to the PR
func (*CherrypickAutoApprove) Name ¶
func (c *CherrypickAutoApprove) Name() string
Name is the name usable in --pr-mungers
func (*CherrypickAutoApprove) RequiredFeatures ¶
func (c *CherrypickAutoApprove) RequiredFeatures() []string
RequiredFeatures is a slice of 'features' that must be provided
type CherrypickQueue ¶
CherrypickQueue will merge PR which meet a set of requirements.
func (*CherrypickQueue) AddFlags ¶
func (c *CherrypickQueue) AddFlags(cmd *cobra.Command, config *github.Config)
AddFlags will add any request flags to the cobra `cmd`
func (*CherrypickQueue) EachLoop ¶
func (c *CherrypickQueue) EachLoop() error
EachLoop is called at the start of every munge loop
func (*CherrypickQueue) Initialize ¶
Initialize will initialize the munger
func (*CherrypickQueue) Munge ¶
func (c *CherrypickQueue) Munge(obj *github.MungeObject)
Munge is the workhorse the will actually make updates to the PR
func (*CherrypickQueue) Name ¶
func (c *CherrypickQueue) Name() string
Name is the name usable in --pr-mungers
func (*CherrypickQueue) RequiredFeatures ¶
func (c *CherrypickQueue) RequiredFeatures() []string
RequiredFeatures is a slice of 'features' that must be provided
type ClaMunger ¶
type ClaMunger struct {
CLAStatusContext string
}
ClaMunger will check the CLA status of the PR and apply a label.
func (*ClaMunger) AddFlags ¶
func (c *ClaMunger) AddFlags(cmd *cobra.Command, config *githubhelper.Config)
AddFlags will add any request flags to the cobra `cmd`.
func (*ClaMunger) Initialize ¶
Initialize will initialize the munger.
func (*ClaMunger) Munge ¶
func (c *ClaMunger) Munge(obj *githubhelper.MungeObject)
Munge is unused by this munger.
func (*ClaMunger) RequiredFeatures ¶
RequiredFeatures is a slice of 'features' that must be provided.
type ClearPickAfterMerge ¶
type ClearPickAfterMerge struct {
// contains filtered or unexported fields
}
ClearPickAfterMerge will remove the the cherrypick-candidate label from any PR that does not have a 'release' milestone set.
func (*ClearPickAfterMerge) AddFlags ¶
func (c *ClearPickAfterMerge) AddFlags(cmd *cobra.Command, config *github.Config)
AddFlags will add any request flags to the cobra `cmd`
func (*ClearPickAfterMerge) EachLoop ¶
func (c *ClearPickAfterMerge) EachLoop() error
EachLoop is called at the start of every munge loop
func (*ClearPickAfterMerge) Initialize ¶
Initialize will initialize the munger
func (*ClearPickAfterMerge) Munge ¶
func (c *ClearPickAfterMerge) Munge(obj *github.MungeObject)
Munge is the workhorse the will actually make updates to the PR
func (*ClearPickAfterMerge) Name ¶
func (c *ClearPickAfterMerge) Name() string
Name is the name usable in --pr-mungers
func (*ClearPickAfterMerge) RequiredFeatures ¶
func (c *ClearPickAfterMerge) RequiredFeatures() []string
RequiredFeatures is a slice of 'features' that must be provided
type CloseStalePR ¶
type CloseStalePR struct{}
CloseStalePR will ask the Bot to close any PullRequest that didn't have any human interactions in `stalePullRequest` duration.
This is done by checking both review and issue comments, and by ignoring comments done with a bot name. We also consider re-open on the PR.
func (CloseStalePR) AddFlags ¶
func (CloseStalePR) AddFlags(cmd *cobra.Command, config *github.Config)
AddFlags will add any request flags to the cobra `cmd`
func (CloseStalePR) EachLoop ¶
func (CloseStalePR) EachLoop() error
EachLoop is called at the start of every munge loop
func (CloseStalePR) Initialize ¶
Initialize will initialize the munger
func (CloseStalePR) Munge ¶
func (CloseStalePR) Munge(obj *github.MungeObject)
Munge is the workhorse that will actually close the PRs
func (CloseStalePR) Name ¶
func (CloseStalePR) Name() string
Name is the name usable in --pr-mungers
func (CloseStalePR) RequiredFeatures ¶
func (CloseStalePR) RequiredFeatures() []string
RequiredFeatures is a slice of 'features' that must be provided
func (CloseStalePR) StaleComments ¶
func (s CloseStalePR) StaleComments(obj *github.MungeObject, comments []*githubapi.IssueComment) []*githubapi.IssueComment
StaleComments returns a slice of stale comments
type CommentDeleter ¶
type CommentDeleter struct{}
CommentDeleter looks for comments which are no longer useful and deletes them
func (CommentDeleter) AddFlags ¶
func (CommentDeleter) AddFlags(cmd *cobra.Command, config *github.Config)
AddFlags will add any request flags to the cobra `cmd`
func (CommentDeleter) EachLoop ¶
func (CommentDeleter) EachLoop() error
EachLoop is called at the start of every munge loop
func (CommentDeleter) Initialize ¶
Initialize will initialize the munger
func (CommentDeleter) Munge ¶
func (CommentDeleter) Munge(obj *github.MungeObject)
Munge is the workhorse the will actually make updates to the PR
func (CommentDeleter) Name ¶
func (CommentDeleter) Name() string
Name is the name usable in --pr-mungers
func (CommentDeleter) RequiredFeatures ¶
func (CommentDeleter) RequiredFeatures() []string
RequiredFeatures is a slice of 'features' that must be provided
type CommentDeleterJenkins ¶
type CommentDeleterJenkins struct{}
CommentDeleterJenkins looks for jenkins comments which are no longer useful and deletes them
func (CommentDeleterJenkins) StaleComments ¶
func (CommentDeleterJenkins) StaleComments(obj *github.MungeObject, comments []*githubapi.IssueComment) []*githubapi.IssueComment
StaleComments returns a slice of comments which are stale
type DocsNeedNoRetest ¶
type DocsNeedNoRetest struct{}
DocsNeedNoRetest automatically labels documentation only pull-requests as retest-not-required
func (DocsNeedNoRetest) AddFlags ¶
func (DocsNeedNoRetest) AddFlags(cmd *cobra.Command, config *github.Config)
AddFlags will add any request flags to the cobra `cmd`
func (DocsNeedNoRetest) EachLoop ¶
func (DocsNeedNoRetest) EachLoop() error
EachLoop is called at the start of every munge loop
func (*DocsNeedNoRetest) Initialize ¶
Initialize will initialize the munger
func (DocsNeedNoRetest) Munge ¶
func (DocsNeedNoRetest) Munge(obj *github.MungeObject)
Munge is the workhorse the will actually make updates to the PR
func (DocsNeedNoRetest) Name ¶
func (DocsNeedNoRetest) Name() string
Name is the name usable in --pr-mungers
func (DocsNeedNoRetest) RequiredFeatures ¶
func (DocsNeedNoRetest) RequiredFeatures() []string
RequiredFeatures is a slice of 'features' that must be provided
type FlakeManager ¶
type FlakeManager struct { OwnerPath string // contains filtered or unexported fields }
FlakeManager files issues for flaky tests.
func (*FlakeManager) AddFlags ¶
func (p *FlakeManager) AddFlags(cmd *cobra.Command, config *github.Config)
AddFlags will add any request flags to the cobra `cmd`
func (*FlakeManager) EachLoop ¶
func (p *FlakeManager) EachLoop() error
EachLoop is called at the start of every munge loop
func (*FlakeManager) Initialize ¶
Initialize will initialize the munger
func (*FlakeManager) Munge ¶
func (p *FlakeManager) Munge(obj *github.MungeObject)
Munge is unused by this munger.
func (*FlakeManager) Name ¶
func (p *FlakeManager) Name() string
Name is the name usable in --pr-mungers
func (*FlakeManager) RequiredFeatures ¶
func (p *FlakeManager) RequiredFeatures() []string
RequiredFeatures is a slice of 'features' that must be provided
type IssueCacher ¶
type IssueCacher struct {
// contains filtered or unexported fields
}
IssueCacher keeps track of issues that track flaky tests, so we can find them.
func (*IssueCacher) AddFlags ¶
func (p *IssueCacher) AddFlags(cmd *cobra.Command, config *github.Config)
AddFlags will add any request flags to the cobra `cmd`
func (*IssueCacher) AllIssuesForKey ¶
func (p *IssueCacher) AllIssuesForKey(key string) []int
AllIssuesForKey returns all known issues matching the key, oldest first.
func (*IssueCacher) Created ¶
func (p *IssueCacher) Created(key string, number int)
Created adds this entry to the cache, in case you try to access it again before another complete pass is made.
func (*IssueCacher) EachLoop ¶
func (p *IssueCacher) EachLoop() error
EachLoop is called at the start of every munge loop
func (*IssueCacher) Initialize ¶
Initialize will initialize the munger
func (*IssueCacher) Munge ¶
func (p *IssueCacher) Munge(obj *github.MungeObject)
Munge is the workhorse the will actually make updates to the PR
func (*IssueCacher) Name ¶
func (p *IssueCacher) Name() string
Name is the name usable in --pr-mungers
func (*IssueCacher) RequiredFeatures ¶
func (p *IssueCacher) RequiredFeatures() []string
RequiredFeatures is a slice of 'features' that must be provided
func (*IssueCacher) Synced ¶
func (p *IssueCacher) Synced() bool
Synced returns true if we've made at least one complete pass through all issues.
type LGTMAfterCommitMunger ¶
type LGTMAfterCommitMunger struct{}
LGTMAfterCommitMunger will remove the LGTM flag from an PR which has been updated since the reviewer added LGTM
func (LGTMAfterCommitMunger) AddFlags ¶
func (LGTMAfterCommitMunger) AddFlags(cmd *cobra.Command, config *github.Config)
AddFlags will add any request flags to the cobra `cmd`
func (LGTMAfterCommitMunger) EachLoop ¶
func (LGTMAfterCommitMunger) EachLoop() error
EachLoop is called at the start of every munge loop
func (LGTMAfterCommitMunger) Initialize ¶
Initialize will initialize the munger
func (LGTMAfterCommitMunger) Munge ¶
func (LGTMAfterCommitMunger) Munge(obj *github.MungeObject)
Munge is the workhorse the will actually make updates to the PR
func (LGTMAfterCommitMunger) Name ¶
func (LGTMAfterCommitMunger) Name() string
Name is the name usable in --pr-mungers
func (LGTMAfterCommitMunger) RequiredFeatures ¶
func (LGTMAfterCommitMunger) RequiredFeatures() []string
RequiredFeatures is a slice of 'features' that must be provided
func (LGTMAfterCommitMunger) StaleComments ¶
func (l LGTMAfterCommitMunger) StaleComments(obj *github.MungeObject, comments []*githubapi.IssueComment) []*githubapi.IssueComment
StaleComments returns a list of comments which are stale
type LGTMHandler ¶
type LGTMHandler struct{}
LGTMHandler will - apply LGTM label if reviewer has commented "/lgtm", or - remove LGTM label if reviewer has commented "/lgtm cancel"
func (LGTMHandler) AddFlags ¶
func (LGTMHandler) AddFlags(cmd *cobra.Command, config *github.Config)
AddFlags will add any request flags to the cobra `cmd`
func (LGTMHandler) EachLoop ¶
func (LGTMHandler) EachLoop() error
EachLoop is called at the start of every munge loop
func (LGTMHandler) Initialize ¶
Initialize will initialize the munger
func (LGTMHandler) Munge ¶
func (h LGTMHandler) Munge(obj *github.MungeObject)
Munge is the workhorse the will actually make updates to the PR
func (LGTMHandler) RequiredFeatures ¶
func (LGTMHandler) RequiredFeatures() []string
RequiredFeatures is a slice of 'features' that must be provided
type LabelMunger ¶
type LabelMunger struct {
TriagerUrl string
}
LabelMunger will update a label on a PR based on how many lines are changed. It will exclude certain files in it's calculations based on the config file provided in --generated-files-config
func (*LabelMunger) AddFlags ¶
func (lm *LabelMunger) AddFlags(cmd *cobra.Command, config *github.Config)
AddFlags will add any request flags to the cobra `cmd`
func (LabelMunger) EachLoop ¶
func (LabelMunger) EachLoop() error
EachLoop is called at the start of every munge loop
func (LabelMunger) Initialize ¶
Initialize will initialize the munger
func (*LabelMunger) Munge ¶
func (lm *LabelMunger) Munge(obj *github.MungeObject)
Munge is the workhorse the will actually make updates to the PR
func (LabelMunger) RequiredFeatures ¶
func (LabelMunger) RequiredFeatures() []string
RequiredFeatures is a slice of 'features' that must be provided
type LabelUnapprovedPicks ¶
type LabelUnapprovedPicks struct{}
LabelUnapprovedPicks will add `do-not-merge` to PRs against a release branch which do not have `cherrypick-approved`.
func (LabelUnapprovedPicks) AddFlags ¶
func (LabelUnapprovedPicks) AddFlags(cmd *cobra.Command, config *github.Config)
AddFlags will add any request flags to the cobra `cmd`
func (LabelUnapprovedPicks) EachLoop ¶
func (LabelUnapprovedPicks) EachLoop() error
EachLoop is called at the start of every munge loop
func (LabelUnapprovedPicks) Initialize ¶
Initialize will initialize the munger
func (LabelUnapprovedPicks) Munge ¶
func (LabelUnapprovedPicks) Munge(obj *github.MungeObject)
Munge is the workhorse the will actually make updates to the PR
func (LabelUnapprovedPicks) Name ¶
func (LabelUnapprovedPicks) Name() string
Name is the name usable in --pr-mungers
func (LabelUnapprovedPicks) RequiredFeatures ¶
func (LabelUnapprovedPicks) RequiredFeatures() []string
RequiredFeatures is a slice of 'features' that must be provided
func (LabelUnapprovedPicks) StaleComments ¶
func (l LabelUnapprovedPicks) StaleComments(obj *github.MungeObject, comments []*githubapi.IssueComment) []*githubapi.IssueComment
StaleComments returns a list of stale comments
type Munger ¶
type Munger interface { // Take action on a specific github issue: Munge(obj *github.MungeObject) AddFlags(cmd *cobra.Command, config *github.Config) Name() string RequiredFeatures() []string Initialize(*github.Config, *features.Features) error EachLoop() error }
Munger is the interface which all mungers must implement to register
func GetActiveMungers ¶
func GetActiveMungers() []Munger
GetActiveMungers returns a slice of all mungers which both registered and were requested by the user
func GetAllMungers ¶
func GetAllMungers() []Munger
GetAllMungers returns a slice of all registered mungers. This list is completely independant of the mungers selected at runtime in --pr-mungers. This is all possible mungers.
type NagFlakeIssues ¶
type NagFlakeIssues struct{}
NagFlakeIssues pings assignees on flaky-test issues
func (NagFlakeIssues) AddFlags ¶
func (NagFlakeIssues) AddFlags(cmd *cobra.Command, config *mgh.Config)
AddFlags will add any request flags to the cobra `cmd`
func (NagFlakeIssues) EachLoop ¶
func (NagFlakeIssues) EachLoop() error
EachLoop is called at the start of every munge loop
func (NagFlakeIssues) Initialize ¶
Initialize will initialize the munger
func (NagFlakeIssues) Munge ¶
func (NagFlakeIssues) Munge(obj *mgh.MungeObject)
Munge is the workhorse the will actually make updates to the PR
func (NagFlakeIssues) Name ¶
func (NagFlakeIssues) Name() string
Name is the name usable in --pr-mungers
func (NagFlakeIssues) RequiredFeatures ¶
func (NagFlakeIssues) RequiredFeatures() []string
RequiredFeatures is a slice of 'features' that must be provided
func (NagFlakeIssues) StaleComments ¶
func (NagFlakeIssues) StaleComments(obj *mgh.MungeObject, comments []*github.IssueComment) []*github.IssueComment
StaleComments returns a slice of stale comments
type NeedsRebaseMunger ¶
type NeedsRebaseMunger struct{}
NeedsRebaseMunger will add the "needs-rebase" label to any issue which is unable to be automatically merged
func (NeedsRebaseMunger) AddFlags ¶
func (NeedsRebaseMunger) AddFlags(cmd *cobra.Command, config *github.Config)
AddFlags will add any request flags to the cobra `cmd`
func (NeedsRebaseMunger) EachLoop ¶
func (NeedsRebaseMunger) EachLoop() error
EachLoop is called at the start of every munge loop
func (NeedsRebaseMunger) Initialize ¶
Initialize will initialize the munger
func (NeedsRebaseMunger) Munge ¶
func (NeedsRebaseMunger) Munge(obj *github.MungeObject)
Munge is the workhorse the will actually make updates to the PR
func (NeedsRebaseMunger) Name ¶
func (NeedsRebaseMunger) Name() string
Name is the name usable in --pr-mungers
func (NeedsRebaseMunger) RequiredFeatures ¶
func (NeedsRebaseMunger) RequiredFeatures() []string
RequiredFeatures is a slice of 'features' that must be provided
func (NeedsRebaseMunger) StaleComments ¶
func (n NeedsRebaseMunger) StaleComments(obj *github.MungeObject, comments []*githubapi.IssueComment) []*githubapi.IssueComment
StaleComments returns a slice of comments which are stale
type OkToTestMunger ¶
type OkToTestMunger struct {
// contains filtered or unexported fields
}
OkToTestMunger looks for situations where a reviewer has LGTM'd a PR, but it isn't ok to test by the testBot, and adds an 'ok to test' comment to the PR.
func (*OkToTestMunger) AddFlags ¶
func (ok *OkToTestMunger) AddFlags(cmd *cobra.Command, config *github.Config)
AddFlags will add any request flags to the cobra `cmd`
func (*OkToTestMunger) EachLoop ¶
func (ok *OkToTestMunger) EachLoop() error
EachLoop is called at the start of every munge loop
func (*OkToTestMunger) Initialize ¶
Initialize will initialize the munger
func (*OkToTestMunger) Munge ¶
func (ok *OkToTestMunger) Munge(obj *github.MungeObject)
Munge is the workhorse the will actually make updates to the PR
func (*OkToTestMunger) Name ¶
func (ok *OkToTestMunger) Name() string
Name is the name usable in --pr-mungers
func (*OkToTestMunger) RequiredFeatures ¶
func (ok *OkToTestMunger) RequiredFeatures() []string
RequiredFeatures is a slice of 'features' that must be provided
func (*OkToTestMunger) StaleComments ¶
func (ok *OkToTestMunger) StaleComments(obj *github.MungeObject, comments []*githubapi.IssueComment) []*githubapi.IssueComment
StaleComments returns a slice of comments which are stale
type OldTestGetter ¶
type OldTestGetter struct { // Keep track of which jobs we've done this for. NumberOfOldTestsToGet int // contains filtered or unexported fields }
OldTestGetter files issues for flaky tests.
func (*OldTestGetter) AddFlags ¶
func (p *OldTestGetter) AddFlags(cmd *cobra.Command, config *github.Config)
AddFlags will add any request flags to the cobra `cmd`
func (*OldTestGetter) EachLoop ¶
func (p *OldTestGetter) EachLoop() error
EachLoop is called at the start of every munge loop
func (*OldTestGetter) Initialize ¶
Initialize will initialize the munger
func (*OldTestGetter) Munge ¶
func (p *OldTestGetter) Munge(obj *github.MungeObject)
Munge is unused by this munger.
func (*OldTestGetter) Name ¶
func (p *OldTestGetter) Name() string
Name is the name usable in --pr-mungers
func (*OldTestGetter) RequiredFeatures ¶
func (p *OldTestGetter) RequiredFeatures() []string
RequiredFeatures is a slice of 'features' that must be provided
type PathLabelMunger ¶
type PathLabelMunger struct { PathLabelFile string // contains filtered or unexported fields }
PathLabelMunger will add labels to PRs based on what files it modified. The mapping of files to labels if provided in a file in --path-label-config
func (*PathLabelMunger) AddFlags ¶
func (p *PathLabelMunger) AddFlags(cmd *cobra.Command, config *github.Config)
AddFlags will add any request flags to the cobra `cmd`
func (*PathLabelMunger) EachLoop ¶
func (p *PathLabelMunger) EachLoop() error
EachLoop is called at the start of every munge loop
func (*PathLabelMunger) Initialize ¶
Initialize will initialize the munger
func (*PathLabelMunger) Munge ¶
func (p *PathLabelMunger) Munge(obj *github.MungeObject)
Munge is the workhorse the will actually make updates to the PR
func (*PathLabelMunger) Name ¶
func (p *PathLabelMunger) Name() string
Name is the name usable in --pr-mungers
func (*PathLabelMunger) RequiredFeatures ¶
func (p *PathLabelMunger) RequiredFeatures() []string
RequiredFeatures is a slice of 'features' that must be provided
type PickMustHaveMilestone ¶
type PickMustHaveMilestone struct{}
PickMustHaveMilestone will remove the the cherrypick-candidate label from any PR that does not have a 'release' milestone set.
func (PickMustHaveMilestone) AddFlags ¶
func (PickMustHaveMilestone) AddFlags(cmd *cobra.Command, config *github.Config)
AddFlags will add any request flags to the cobra `cmd`
func (PickMustHaveMilestone) EachLoop ¶
func (PickMustHaveMilestone) EachLoop() error
EachLoop is called at the start of every munge loop
func (PickMustHaveMilestone) Initialize ¶
Initialize will initialize the munger
func (PickMustHaveMilestone) Munge ¶
func (PickMustHaveMilestone) Munge(obj *github.MungeObject)
Munge is the workhorse the will actually make updates to the PR
func (PickMustHaveMilestone) Name ¶
func (PickMustHaveMilestone) Name() string
Name is the name usable in --pr-mungers
func (PickMustHaveMilestone) RequiredFeatures ¶
func (PickMustHaveMilestone) RequiredFeatures() []string
RequiredFeatures is a slice of 'features' that must be provided
func (PickMustHaveMilestone) StaleComments ¶
func (p PickMustHaveMilestone) StaleComments(obj *github.MungeObject, comments []*githubapi.IssueComment) []*githubapi.IssueComment
StaleComments returns a slice of stale comments
type PublisherMunger ¶
type PublisherMunger struct { // Command for the 'publisher' munger to run periodically. PublishCommand string // contains filtered or unexported fields }
PublisherMunger publishes content from one repository to another one.
func (*PublisherMunger) AddFlags ¶
func (p *PublisherMunger) AddFlags(cmd *cobra.Command, config *github.Config)
AddFlags will add any request flags to the cobra `cmd`
func (*PublisherMunger) EachLoop ¶
func (p *PublisherMunger) EachLoop() error
EachLoop is called at the start of every munge loop
func (*PublisherMunger) Initialize ¶
Initialize will initialize the munger
func (*PublisherMunger) Munge ¶
func (p *PublisherMunger) Munge(obj *github.MungeObject)
Munge is the workhorse the will actually make updates to the PR
func (*PublisherMunger) Name ¶
func (p *PublisherMunger) Name() string
Name is the name usable in --pr-mungers
func (*PublisherMunger) RequiredFeatures ¶
func (p *PublisherMunger) RequiredFeatures() []string
RequiredFeatures is a slice of 'features' that must be provided
type RebuildMunger ¶
type RebuildMunger struct {
// contains filtered or unexported fields
}
RebuildMunger looks for situations where a someone has asked for an e2e rebuild, but hasn't provided an issue
func (*RebuildMunger) AddFlags ¶
func (r *RebuildMunger) AddFlags(cmd *cobra.Command, config *github.Config)
AddFlags will add any request flags to the cobra `cmd`
func (*RebuildMunger) EachLoop ¶
func (r *RebuildMunger) EachLoop() error
EachLoop is called at the start of every munge loop
func (*RebuildMunger) Initialize ¶
Initialize will initialize the munger
func (*RebuildMunger) Munge ¶
func (r *RebuildMunger) Munge(obj *github.MungeObject)
Munge is the workhorse the will actually make updates to the PR
func (*RebuildMunger) Name ¶
func (r *RebuildMunger) Name() string
Name is the name usable in --pr-mungers
func (*RebuildMunger) RequiredFeatures ¶
func (r *RebuildMunger) RequiredFeatures() []string
RequiredFeatures is a slice of 'features' that must be provided
func (*RebuildMunger) StaleComments ¶
func (r *RebuildMunger) StaleComments(obj *github.MungeObject, comments []*githubapi.IssueComment) []*githubapi.IssueComment
StaleComments returns a slice of stale comments
type ReleaseNoteLabel ¶
type ReleaseNoteLabel struct {
// contains filtered or unexported fields
}
ReleaseNoteLabel will add the doNotMergeLabel to a PR which has not set one of the appropriete 'release-note-*' labels but has LGTM
func (*ReleaseNoteLabel) AddFlags ¶
func (r *ReleaseNoteLabel) AddFlags(cmd *cobra.Command, config *github.Config)
AddFlags will add any request flags to the cobra `cmd`
func (*ReleaseNoteLabel) EachLoop ¶
func (r *ReleaseNoteLabel) EachLoop() error
EachLoop is called at the start of every munge loop
func (*ReleaseNoteLabel) Initialize ¶
Initialize will initialize the munger
func (*ReleaseNoteLabel) Munge ¶
func (r *ReleaseNoteLabel) Munge(obj *github.MungeObject)
Munge is the workhorse the will actually make updates to the PR
func (*ReleaseNoteLabel) Name ¶
func (r *ReleaseNoteLabel) Name() string
Name is the name usable in --pr-mungers
func (*ReleaseNoteLabel) RequiredFeatures ¶
func (r *ReleaseNoteLabel) RequiredFeatures() []string
RequiredFeatures is a slice of 'features' that must be provided
func (*ReleaseNoteLabel) StaleComments ¶
func (r *ReleaseNoteLabel) StaleComments(obj *github.MungeObject, comments []*githubapi.IssueComment) []*githubapi.IssueComment
StaleComments returns a slice of stale comments
type SizeMunger ¶
type SizeMunger struct { GeneratedFilesFile string // contains filtered or unexported fields }
SizeMunger will update a label on a PR based on how many lines are changed. It will exclude certain files in it's calculations based on the config file provided in --generated-files-config
func (*SizeMunger) AddFlags ¶
func (s *SizeMunger) AddFlags(cmd *cobra.Command, config *github.Config)
AddFlags will add any request flags to the cobra `cmd`
func (SizeMunger) EachLoop ¶
func (SizeMunger) EachLoop() error
EachLoop is called at the start of every munge loop
func (*SizeMunger) Initialize ¶
Initialize will initialize the munger
func (*SizeMunger) Munge ¶
func (s *SizeMunger) Munge(obj *github.MungeObject)
Munge is the workhorse the will actually make updates to the PR
func (SizeMunger) RequiredFeatures ¶
func (SizeMunger) RequiredFeatures() []string
RequiredFeatures is a slice of 'features' that must be provided
func (*SizeMunger) StaleComments ¶
func (s *SizeMunger) StaleComments(obj *github.MungeObject, comments []*githubapi.IssueComment) []*githubapi.IssueComment
StaleComments returns a slice of stale comments
type StaleComment ¶
type StaleComment interface {
StaleComments(*github.MungeObject, []*githubapi.IssueComment) []*githubapi.IssueComment
}
StaleComment is an interface for a munger which writes comments which might go stale and which should be cleaned up
type StaleGreenCI ¶
type StaleGreenCI struct {
// contains filtered or unexported fields
}
StaleGreenCI will re-run passed tests for LGTM PRs if they are more than 96 hours old.
func (*StaleGreenCI) AddFlags ¶
func (s *StaleGreenCI) AddFlags(cmd *cobra.Command, config *github.Config)
AddFlags will add any request flags to the cobra `cmd`
func (*StaleGreenCI) EachLoop ¶
func (s *StaleGreenCI) EachLoop() error
EachLoop is called at the start of every munge loop
func (*StaleGreenCI) Initialize ¶
Initialize will initialize the munger
func (*StaleGreenCI) Munge ¶
func (s *StaleGreenCI) Munge(obj *github.MungeObject)
Munge is the workhorse the will actually make updates to the PR
func (*StaleGreenCI) Name ¶
func (s *StaleGreenCI) Name() string
Name is the name usable in --pr-mungers
func (*StaleGreenCI) RequiredFeatures ¶
func (s *StaleGreenCI) RequiredFeatures() []string
RequiredFeatures is a slice of 'features' that must be provided
func (*StaleGreenCI) StaleComments ¶
func (s *StaleGreenCI) StaleComments(obj *github.MungeObject, comments []*githubapi.IssueComment) []*githubapi.IssueComment
StaleComments returns a slice of stale comments
type StalePendingCI ¶
type StalePendingCI struct {
// contains filtered or unexported fields
}
StalePendingCI will ask the testBot-to test any PR with a LGTM that has been pending for more than 24 hours. This can happen when the jenkins VM is restarted.
The real fix would be for the jenkins VM restart to not move every single PR to pending without actually testing...
But this is our world and so we should really do this for all PRs which aren't likely to get another push (everything that is mergeable). Since that can be a lot of PRs, I'm just doing it for the LGTM PRs automatically...
func (*StalePendingCI) AddFlags ¶
func (s *StalePendingCI) AddFlags(cmd *cobra.Command, config *github.Config)
AddFlags will add any request flags to the cobra `cmd`
func (*StalePendingCI) EachLoop ¶
func (s *StalePendingCI) EachLoop() error
EachLoop is called at the start of every munge loop
func (*StalePendingCI) Initialize ¶
Initialize will initialize the munger
func (*StalePendingCI) Munge ¶
func (s *StalePendingCI) Munge(obj *github.MungeObject)
Munge is the workhorse the will actually make updates to the PR
func (*StalePendingCI) Name ¶
func (s *StalePendingCI) Name() string
Name is the name usable in --pr-mungers
func (*StalePendingCI) RequiredFeatures ¶
func (s *StalePendingCI) RequiredFeatures() []string
RequiredFeatures is a slice of 'features' that must be provided
func (*StalePendingCI) StaleComments ¶
func (s *StalePendingCI) StaleComments(obj *github.MungeObject, comments []*githubapi.IssueComment) []*githubapi.IssueComment
StaleComments returns a slice of stale comments
type SubmitQueue ¶
type SubmitQueue struct { BlockingJobNames []string NonBlockingJobNames []string PresubmitJobNames []string WeakStableJobNames []string // If FakeE2E is true, don't try to connect to JenkinsHost, all jobs are passing. FakeE2E bool Committers string RequiredStatusContexts []string DoNotMergeMilestones []string RequiredRetestContexts []string RetestBody string Metadata submitQueueMetadata AdminPort int sync.Mutex // contains filtered or unexported fields }
SubmitQueue will merge PR which meet a set of requirements.
PR must have LGTM after the last commit PR must have passed all github CI checks The google internal jenkins instance must be passing the BlockingJobNames e2e tests
func (*SubmitQueue) AddFlags ¶
func (sq *SubmitQueue) AddFlags(cmd *cobra.Command, config *github.Config)
AddFlags will add any request flags to the cobra `cmd`
func (*SubmitQueue) EachLoop ¶
func (sq *SubmitQueue) EachLoop() error
EachLoop is called at the start of every munge loop
func (*SubmitQueue) EmergencyStopHTTP ¶
func (sq *SubmitQueue) EmergencyStopHTTP(res http.ResponseWriter, req *http.Request)
EmergencyStopHTTP sets the emergency stop flag. It expects the path of req.URL to contain either "emergency/stop", "emergency/resume", or "emergency/status".
func (*SubmitQueue) Initialize ¶
Initialize will initialize the munger
func (*SubmitQueue) Munge ¶
func (sq *SubmitQueue) Munge(obj *github.MungeObject)
Munge is the workhorse the will actually make updates to the PR
func (*SubmitQueue) Name ¶
func (sq *SubmitQueue) Name() string
Name is the name usable in --pr-mungers
func (*SubmitQueue) RequiredFeatures ¶
func (sq *SubmitQueue) RequiredFeatures() []string
RequiredFeatures is a slice of 'features' that must be provided
func (*SubmitQueue) SetMergeStatus ¶
func (sq *SubmitQueue) SetMergeStatus(obj *github.MungeObject, reason string)
SetMergeStatus will set the status given a particular PR. This function should be used instead of manipulating the prStatus directly as sq.Lock() must be called when manipulating that structure `obj` is the active github object `reason` is the new 'status' for this object
func (*SubmitQueue) StaleComments ¶
func (sq *SubmitQueue) StaleComments(obj *github.MungeObject, comments []*githubapi.IssueComment) []*githubapi.IssueComment
StaleComments returns a slice of stale comments
Source Files ¶
- assign-fixes.go
- block_paths.go
- blunderbuss.go
- check-labels.go
- cherrypick-auto-approve.go
- cherrypick-clear-after-merge.go
- cherrypick-label-unapproved.go
- cherrypick-must-have-milestone.go
- cherrypick-queue.go
- cla.go
- close-stale-pr.go
- comment-deleter-jenkins.go
- comment-deleter.go
- doc.go
- docs-no-retest.go
- flake-manager.go
- issue-cacher.go
- issue-categorizer.go
- lgtm_after_commit.go
- lgtm_handler.go
- mungers.go
- nag-flake-issues.go
- needs_rebase.go
- ok-to-test.go
- old-test-getter.go
- path_label.go
- publisher.go
- rebuild.go
- release-note-label.go
- size.go
- stale-green-ci.go
- stale-pending-ci.go
- submit-queue.go