Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Check ¶
type Check interface {
Info() CheckInfo
Init(ws leeway.Workspace) error
RunPkg(pkg *leeway.Package) ([]Finding, error)
RunCmp(pkg *leeway.Component) ([]Finding, error)
}
Check implements a vet check
func ComponentCheck ¶
ComponentCheck produces a new check for a leeway component
func PackageCheck ¶
func PackageCheck(name, desc string, tpe leeway.PackageType, chk func(pkg *leeway.Package) ([]Finding, error)) Check
PackageCheck produces a new check for a leeway package
type CheckInfo ¶
type CheckInfo struct {
Name string
Description string
PackageCheck bool
AppliesToType *leeway.PackageType
}
CheckInfo describes a check
type Finding ¶
type Finding struct {
Check string
Component *leeway.Component
Package *leeway.Package
Description string
Error bool
}
Finding describes a check finding. If the package is nil, the finding applies to the component
func (Finding) MarshalJSON ¶
MarshalJSON marshals a finding to JSON
type RunOpt ¶
type RunOpt func(*runOptions)
RunOpt modifies the run behaviour
func OnComponents ¶
OnComponents makes run check these components only
func OnPackages ¶
OnPackages makes run check these packages only
Click to show internal directories.
Click to hide internal directories.