Documentation ¶
Overview ¶
Package codeowners contains logic for loading and parsing patterns in CODEOWNERS files
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func PathIsCodeowners ¶
PathIsCodeowners returns whether or not the provided path is for a valid CODEOWNERS file see: https://help.github.com/articles/about-code-owners/#codeowners-file-location
Types ¶
type Codeowners ¶
type Codeowners []OwnerEntry
Codeowners is the deserialized form of a given CODEOWNERS file
func LoadFromFilesystem ¶
func LoadFromFilesystem(fs billy.Filesystem) (Codeowners, error)
LoadFromFilesystem loads and deserializes a CODEOWNERS file from the given repository, if one exists
func (*Codeowners) Owners ¶
func (o *Codeowners) Owners(path string) []string
Owners returns the list of owners for a given path, in the event of a match
type OwnerEntry ¶
type OwnerEntry struct { Pattern git.IgnorePattern Owners []string // contains filtered or unexported fields }
OwnerEntry contains owners for a given pattern
func (OwnerEntry) String ¶
func (e OwnerEntry) String() string
Click to show internal directories.
Click to hide internal directories.