Skip to content

Add an option to set the Go version #1143

@ldez

Description

@ldez

Summary

Hello,

I know that my request is really specific to golangci-lint, and if you don't want to do that I will understand.

The new way for gosec to detect the Go version has a huge impact on golangci-lint performances.

The best solution for us is to have an option to set the Go version to bypass the usage of go list.

Steps to reproduce the behavior

golangci/golangci-lint#4735

gosec version

v2.20.0

Go version (output of 'go version')

$ go version
go version go1.22.3 linux/amd64

Operating system / Environment

Not dependent on the OS

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions