Skip to content

Allow custom markers with values #124

Open
@justenstall

Description

@justenstall

Allow custom markers to have a value like kubebuilder markers.

type Config struct {
   // +kubebuilder:default=25
   MaxOpenConns int `json:"maxOpenConns,omitempty"`
}

Motivation is to define an env custom marker to generate an extra column with the equivalent environment variable name.

type Config struct {
   // +env="MAX_OPEN_CONNS"
   MaxOpenConns int `json:"maxOpenConns,omitempty"`
}

I tried implementing this using the existing processor.customMarkers config and modified templates like the examples, but it seems like the markers are not matched if they are followed by an equals sign.

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