Merge pull request #62 from vbatts/lint

mage: update golangci-lint and ignore stdlib from being checked
This commit is contained in:
Vincent Batts 2023-10-23 08:37:43 -04:00 committed by GitHub
commit 2f784a1d24
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 3 deletions

View File

@ -5,7 +5,7 @@ on:
branches_ignore: []
jobs:
build:
lint:
runs-on: ubuntu-latest
strategy:
matrix:

View File

@ -57,7 +57,7 @@ func Vet() error {
func Lint() error {
mg.Deps(InstallToolsLint)
fmt.Println("Linting...")
cmd := exec.Command("golangci-lint", "run")
cmd := exec.Command("golangci-lint", "run", "--skip-dirs", "(^|/).gvm/gos($|/)", "--skip-dirs", "(^|/)go/pkg/mod($|/)")
cmd.Stdout = Stdout
cmd.Stderr = Stderr
return cmd.Run()
@ -97,7 +97,7 @@ func InstallTools() error {
func InstallToolsLint() error {
fmt.Println("Installing Deps...")
cmd := exec.Command("go", "install", "github.com/golangci/golangci-lint/cmd/golangci-lint@v1.51.2")
cmd := exec.Command("go", "install", "github.com/golangci/golangci-lint/cmd/golangci-lint@v1.55.0")
cmd.Stdout = Stdout
cmd.Stderr = Stderr
return cmd.Run()