Documentation
¶
Overview ¶
Package codeowners needs documentation.
Index ¶
Constants ¶
View Source
const ( // EmailOwner is the owner type for email addresses. EmailOwner string = "email" // TeamOwner is the owner type for GitHub teams. TeamOwner string = "team" // UsernameOwner is the owner type for GitHub usernames. UsernameOwner string = "username" )
Variables ¶
This section is empty.
Functions ¶
func ConsolidateTree ¶
func ConsolidateTree(tree *FileTree)
Types ¶
type FileTree ¶
type FileTree struct {
// contains filtered or unexported fields
}
func NewFileTree ¶
type Owner ¶
type Owner struct {
// Value is the name of the owner: the email addres, team name, or username.
Value string
// Type will be one of 'email', 'team', or 'username'.
Type string
}
Owner represents an owner found in a rule.
type Rule ¶
Rule is a CODEOWNERS rule that maps a gitignore-style path pattern to a set of owners.
func LoadFileAtRef ¶
LoadFileAtRef loads and parses a CODEOWNERS file from a historical commit. If ref is an empty string, file will be read from disk.
func LoadFileFromStandardLocation ¶
LoadFileFromStandardLocation loads and parses a CODEOWNERS file at one of the standard locations for CODEOWNERS files (./, .github/, docs/). If run from a git repository, all paths are relative to the repository root.
func (*Rule) RawPattern ¶
RawPattern returns the rule's gitignore-style path pattern.
Click to show internal directories.
Click to hide internal directories.