Skip to content

Commit a0aacf9

Browse files
committed
use ttempdir v0.3.0
1 parent e279d6b commit a0aacf9

File tree

3 files changed

+22
-22
lines changed

3 files changed

+22
-22
lines changed

go.mod

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,7 @@ require (
8383
github.com/nishanths/exhaustive v0.12.0
8484
github.com/nishanths/predeclared v0.2.2
8585
github.com/nunnatsa/ginkgolinter v0.16.2
86-
github.com/peczenyj/ttempdir v0.2.2
86+
github.com/peczenyj/ttempdir v0.3.0
8787
github.com/pelletier/go-toml/v2 v2.2.2
8888
github.com/polyfloyd/go-errorlint v1.5.2
8989
github.com/quasilyte/go-ruleguard/dsl v0.3.22
@@ -126,7 +126,7 @@ require (
126126
go-simpler.org/sloglint v0.7.1
127127
go.uber.org/automaxprocs v1.5.3
128128
golang.org/x/exp v0.0.0-20240103183307-be819d1f06fc
129-
golang.org/x/tools v0.21.0
129+
golang.org/x/tools v0.22.0
130130
gopkg.in/yaml.v3 v3.0.1
131131
honnef.co/go/tools v0.4.7
132132
mvdan.cc/gofumpt v0.6.0
@@ -191,9 +191,9 @@ require (
191191
go.uber.org/multierr v1.6.0 // indirect
192192
go.uber.org/zap v1.24.0 // indirect
193193
golang.org/x/exp/typeparams v0.0.0-20240314144324-c7f7c6466f7f // indirect
194-
golang.org/x/mod v0.17.0 // indirect
194+
golang.org/x/mod v0.18.0 // indirect
195195
golang.org/x/sync v0.7.0 // indirect
196-
golang.org/x/sys v0.20.0 // indirect
196+
golang.org/x/sys v0.21.0 // indirect
197197
golang.org/x/text v0.15.0 // indirect
198198
google.golang.org/protobuf v1.33.0 // indirect
199199
gopkg.in/ini.v1 v1.67.0 // indirect

go.sum

Lines changed: 10 additions & 10 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

pkg/golinters/ttempdir/ttempdir.go

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,30 +1,30 @@
11
package ttempdir
22

33
import (
4-
"github.com/peczenyj/ttempdir"
4+
"github.com/peczenyj/ttempdir/analyzer"
55
"golang.org/x/tools/go/analysis"
66

77
"github.com/golangci/golangci-lint/pkg/config"
88
"github.com/golangci/golangci-lint/pkg/goanalysis"
99
)
1010

1111
func New(settings *config.TtempdirSettings) *goanalysis.Linter {
12-
a := ttempdir.Analyzer
12+
ttempdirAnalyzer := analyzer.New()
1313

1414
var cfg map[string]map[string]any
1515
if settings != nil {
1616
cfg = map[string]map[string]any{
17-
a.Name: {
18-
ttempdir.A: settings.All,
19-
ttempdir.MRL: settings.MaxRecursionLevel,
17+
ttempdirAnalyzer.Name: {
18+
analyzer.FlagAllName: settings.All,
19+
analyzer.FlagMaxRecursionLevelName: settings.MaxRecursionLevel,
2020
},
2121
}
2222
}
2323

2424
return goanalysis.NewLinter(
25-
a.Name,
26-
a.Doc,
27-
[]*analysis.Analyzer{a},
25+
ttempdirAnalyzer.Name,
26+
ttempdirAnalyzer.Doc,
27+
[]*analysis.Analyzer{ttempdirAnalyzer},
2828
cfg,
2929
).WithLoadMode(goanalysis.LoadModeSyntax)
3030
}

0 commit comments

Comments
 (0)