Documentation
¶
Overview ¶
Package bufbreaking contains the breaking change detection functionality.
The primary entry point to this package is the Handler.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Config ¶
type Config struct {
// Checkers are the checkers to run.
//
// Checkers will be sorted by first categories, then id when Configs are
// created from this package, i.e. created wth ConfigBuilder.NewConfig.
Checkers []Checker
IgnoreIDToRootPaths map[string]map[string]struct{}
IgnoreRootPaths map[string]struct{}
}
Config is the check config.
func NewConfig ¶ added in v0.15.0
func NewConfig(externalConfig bufbreakingcfg.ExternalConfig) (*Config, error)
NewConfig returns a new Config.
type Handler ¶
type Handler interface {
// Check runs the breaking checks.
//
// The image should have source code info for this to work properly. The previousImage
// does not need to have source code info.
//
// Images should be filtered with regards to imports before passing to this function.
Check(
ctx context.Context,
config *Config,
previousImage bufimage.Image,
image bufimage.Image,
) ([]bufanalysis.FileAnnotation, error)
}
Handler handles the main breaking functionality.
Click to show internal directories.
Click to hide internal directories.