Documentation ¶
Index ¶
- Constants
- type Config
- func (lc Config) AllNames() []string
- func (lc Config) GetSpeed() int
- func (lc Config) Name() string
- func (lc Config) WithAlternativeNames(names ...string) Config
- func (lc Config) WithPresets(presets ...string) Config
- func (lc Config) WithSSA() Config
- func (lc Config) WithSpeed(speed int) Config
- func (lc Config) WithTypeInfo() Config
- func (lc Config) WithURL(url string) Config
- type Context
- type Linter
Constants ¶
View Source
const ( PresetFormatting = "format" PresetComplexity = "complexity" PresetStyle = "style" PresetBugs = "bugs" PresetUnused = "unused" PresetPerformance = "performance" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct { Linter Linter EnabledByDefault bool NeedsTypeInfo bool NeedsSSARepr bool InPresets []string Speed int // more value means faster execution of linter AlternativeNames []string OriginalURL string // URL of original (not forked) repo, needed for autogenerated README }
func (Config) WithAlternativeNames ¶ added in v1.10.2
func (Config) WithPresets ¶
func (Config) WithTypeInfo ¶ added in v1.11.1
type Context ¶
type Context struct { Packages []*packages.Package NotCompilingPackages []*packages.Package LoaderConfig *loader.Config // deprecated, don't use for new linters Program *loader.Program // deprecated, use Packages for new linters SSAProgram *ssa.Program Cfg *config.Config ASTCache *astcache.Cache Log logutils.Log }
func (*Context) Settings ¶
func (c *Context) Settings() *config.LintersSettings
Click to show internal directories.
Click to hide internal directories.