boolnames: make default whitelist include 'ok'
This commit is contained in:
24
pkg/ifinit/plugin.go
Normal file
24
pkg/ifinit/plugin.go
Normal file
@@ -0,0 +1,24 @@
|
||||
package ifinit
|
||||
|
||||
import (
|
||||
"github.com/golangci/plugin-module-register/register"
|
||||
"golang.org/x/tools/go/analysis"
|
||||
)
|
||||
|
||||
func init() {
|
||||
register.Plugin("ifinit", New)
|
||||
}
|
||||
|
||||
type plugin struct{}
|
||||
|
||||
func New(any) (register.LinterPlugin, error) {
|
||||
return &plugin{}, nil
|
||||
}
|
||||
|
||||
func (p *plugin) BuildAnalyzers() ([]*analysis.Analyzer, error) {
|
||||
return []*analysis.Analyzer{Analyzer}, nil
|
||||
}
|
||||
|
||||
func (p *plugin) GetLoadMode() string {
|
||||
return register.LoadModeTypesInfo
|
||||
}
|
||||
Reference in New Issue
Block a user