I have several protobuf structs that were generated to golang code. Inside structs I have imported generated fields:
type GeneratedStruct struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
...
}
I'm using golangci-lint version 1.32.2 This linter contains exhaustivestruct linter that I want to use (I dont want to exclude it).
I tried to do something like this in .golangci.yaml file:
linters-settings:
exhaustive:
check-generated: false
exhaustivestruct:
check-generated: false
But this linter is still returning errors on generated structs.
Is there a way to disable this linter on such generated structs?
BTW, I know about //nolint: ... but it is a little nerving to write it all over the code.
Thank you.