Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func New ¶
func New(settings any) (register.LinterPlugin, error)
New creates a new LLPlugin from the given settings. It satisfies the signature required by the golangci-lint linter for plugins.
func NewTxScope ¶
func NewTxScope(_ any) (register.LinterPlugin, error)
NewTxScope creates a plugin that detects access to the transaction origin from within an ExecTx callback.
Types ¶
type LLConfig ¶
type LLConfig struct {
LineLength int `json:"line-length"`
TabWidth int `json:"tab-width"`
LogRegex string `json:"log-regex"`
}
LLConfig is the configuration for the ll linter.
type LLPlugin ¶
type LLPlugin struct {
// contains filtered or unexported fields
}
LLPlugin is a golangci-linter plugin that can be used to check that code line lengths do not exceed a certain limit.
func (*LLPlugin) BuildAnalyzers ¶
BuildAnalyzers creates the analyzers for the ll linter.
NOTE: This is part of the register.LinterPlugin interface.
func (*LLPlugin) GetLoadMode ¶
GetLoadMode returns the load mode for the ll linter.
NOTE: This is part of the register.LinterPlugin interface.
type TxScopePlugin ¶
type TxScopePlugin struct{}
TxScopePlugin prevents transaction callbacks from acquiring another connection from the executor that owns the current transaction.
func (*TxScopePlugin) BuildAnalyzers ¶
func (t *TxScopePlugin) BuildAnalyzers() ([]*analysis.Analyzer, error)
BuildAnalyzers returns the analyzers provided by the plugin.
NOTE: This is part of the register.LinterPlugin interface.
func (*TxScopePlugin) GetLoadMode ¶
func (t *TxScopePlugin) GetLoadMode() string
GetLoadMode requests type information so references to the same executor can be matched by object identity instead of variable spelling.
NOTE: This is part of the register.LinterPlugin interface.