File tree 4 files changed +92
-0
lines changed
4 files changed +92
-0
lines changed Original file line number Diff line number Diff line change
1
+ // This file can build as a plugin for golangci-lint by below command.
2
+ // go build -buildmode=plugin -o unclosetx.so github.com/gcpug/zagane/passes/unclosetx/plugin
3
+ // See: https://golangci-lint.run/contributing/new-linters/#how-to-add-a-private-linter-to-golangci-lint
4
+
5
+ package main
6
+
7
+ import (
8
+ "github.com/gcpug/zagane/passes/unclosetx"
9
+ "golang.org/x/tools/go/analysis"
10
+ )
11
+
12
+ // AnalyzerPlugin provides analyzers as a plugin.
13
+ // It follows golangci-lint style plugin.
14
+ var AnalyzerPlugin analyzerPlugin
15
+
16
+ type analyzerPlugin struct {}
17
+
18
+ func (analyzerPlugin ) GetAnalyzers () []* analysis.Analyzer {
19
+ return []* analysis.Analyzer {
20
+ unclosetx .Analyzer ,
21
+ }
22
+ }
Original file line number Diff line number Diff line change
1
+ // This file can build as a plugin for golangci-lint by below command.
2
+ // go build -buildmode=plugin -o unstopiter.so github.com/gcpug/zagane/passes/unstopiter/plugin
3
+ // See: https://golangci-lint.run/contributing/new-linters/#how-to-add-a-private-linter-to-golangci-lint
4
+
5
+ package main
6
+
7
+ import (
8
+ "github.com/gcpug/zagane/passes/unstopiter"
9
+ "golang.org/x/tools/go/analysis"
10
+ )
11
+
12
+ // AnalyzerPlugin provides analyzers as a plugin.
13
+ // It follows golangci-lint style plugin.
14
+ var AnalyzerPlugin analyzerPlugin
15
+
16
+ type analyzerPlugin struct {}
17
+
18
+ func (analyzerPlugin ) GetAnalyzers () []* analysis.Analyzer {
19
+ return []* analysis.Analyzer {
20
+ unstopiter .Analyzer ,
21
+ }
22
+ }
Original file line number Diff line number Diff line change
1
+ // This file can build as a plugin for golangci-lint by below command.
2
+ // go build -buildmode=plugin -o wraperr.so github.com/gcpug/zagane/passes/wraperr/plugin
3
+ // See: https://golangci-lint.run/contributing/new-linters/#how-to-add-a-private-linter-to-golangci-lint
4
+
5
+ package main
6
+
7
+ import (
8
+ "github.com/gcpug/zagane/passes/wraperr"
9
+ "golang.org/x/tools/go/analysis"
10
+ )
11
+
12
+ // AnalyzerPlugin provides analyzers as a plugin.
13
+ // It follows golangci-lint style plugin.
14
+ var AnalyzerPlugin analyzerPlugin
15
+
16
+ type analyzerPlugin struct {}
17
+
18
+ func (analyzerPlugin ) GetAnalyzers () []* analysis.Analyzer {
19
+ return []* analysis.Analyzer {
20
+ wraperr .Analyzer ,
21
+ }
22
+ }
Original file line number Diff line number Diff line change
1
+ // This file can build as a plugin for golangci-lint by below command.
2
+ // go build -buildmode=plugin -o zagane.so github.com/gcpug/zagane/plugin
3
+ // See: https://golangci-lint.run/contributing/new-linters/#how-to-add-a-private-linter-to-golangci-lint
4
+
5
+ package main
6
+
7
+ import (
8
+ "github.com/gcpug/zagane/passes/unclosetx"
9
+ "github.com/gcpug/zagane/passes/unstopiter"
10
+ "github.com/gcpug/zagane/passes/wraperr"
11
+ "golang.org/x/tools/go/analysis"
12
+ )
13
+
14
+ // AnalyzerPlugin provides analyzers as a plugin.
15
+ // It follows golangci-lint style plugin.
16
+ var AnalyzerPlugin analyzerPlugin
17
+
18
+ type analyzerPlugin struct {}
19
+
20
+ func (analyzerPlugin ) GetAnalyzers () []* analysis.Analyzer {
21
+ return []* analysis.Analyzer {
22
+ unstopiter .Analyzer ,
23
+ unclosetx .Analyzer ,
24
+ wraperr .Analyzer ,
25
+ }
26
+ }
You can’t perform that action at this time.
0 commit comments