-
Notifications
You must be signed in to change notification settings - Fork 13
Closed
Description
I have structs like:
type Build struct {
Version string `json:"version,omitempty"`
BuildTimestamp string `json:"buildTimestamp,omitempty"`
Revision string `json:"revision,omitempty"`
}
type Site struct {
Build *Build `json:"build,omitempty" yaml:"-"`
Index string `json:"index" yaml:"index"`
Title string `json:"title" yaml:"title"`
SizeField bool `json:"-" yaml:"sizeField,omitempty"`
}
Linter complains that the given struct should be annotated with the
yaml tag
. It seems it is complaining that Build
has no yaml
tag, but it doe not need it because it is an ignored field for yaml, see yaml:"-"
there.
tmzane
Metadata
Metadata
Assignees
Labels
No labels