Skip to content

Commit f93c2e0

Browse files
committed
Fix #164: update GAS to the latest gosec
1 parent 8a478c4 commit f93c2e0

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

60 files changed

+2492
-454
lines changed

Gopkg.lock

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

Gopkg.toml

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -29,11 +29,6 @@
2929
branch = "fix-crash-on-nil-constant"
3030
source = "github.com/golangci/unparam"
3131

32-
[[constraint]]
33-
name = "github.com/GoASTScanner/gas"
34-
branch = "master"
35-
source = "github.com/golangci/gas"
36-
3732
[prune]
3833
go-tests = true
3934
unused-packages = true

pkg/golinters/gas.go

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -8,10 +8,10 @@ import (
88
"log"
99
"strconv"
1010

11-
"github.com/GoASTScanner/gas"
12-
"github.com/GoASTScanner/gas/rules"
1311
"github.com/golangci/golangci-lint/pkg/lint/linter"
1412
"github.com/golangci/golangci-lint/pkg/result"
13+
"github.com/golangci/gosec"
14+
"github.com/golangci/gosec/rules"
1515
)
1616

1717
type Gosec struct{}
@@ -25,10 +25,10 @@ func (Gosec) Desc() string {
2525
}
2626

2727
func (lint Gosec) Run(ctx context.Context, lintCtx *linter.Context) ([]result.Issue, error) {
28-
gasConfig := gas.NewConfig()
28+
gasConfig := gosec.NewConfig()
2929
enabledRules := rules.Generate()
3030
logger := log.New(ioutil.Discard, "", 0)
31-
analyzer := gas.NewAnalyzer(gasConfig, logger)
31+
analyzer := gosec.NewAnalyzer(gasConfig, logger)
3232
analyzer.LoadRules(enabledRules.Builders())
3333

3434
analyzer.ProcessProgram(lintCtx.Program)

vendor/github.com/GoASTScanner/gas/Dockerfile

Lines changed: 0 additions & 8 deletions
This file was deleted.

vendor/github.com/GoASTScanner/gas/Makefile

Lines changed: 0 additions & 48 deletions
This file was deleted.

vendor/github.com/GoASTScanner/gas/rules/readfile.go

Lines changed: 0 additions & 63 deletions
This file was deleted.

vendor/github.com/golang/mock/AUTHORS

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

vendor/github.com/golang/mock/CONTRIBUTORS

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

0 commit comments

Comments
 (0)