Documentation ¶
Index ¶
Constants ¶
View Source
const (
EnvVarPrefix = "GENERATE_API_REFERENCE_"
)
Variables ¶
View Source
var ( Scheme = runtime.NewScheme() Codecs = serializer.NewCodecFactory(Scheme, serializer.EnableStrict) )
Functions ¶
func IndexNestedProps ¶
func IndexNestedProps(props map[string]apiextensionsv1.JSONSchemaProps) map[string]apiextensionsv1.JSONSchemaProps
IndexNestedProps will traverse all object and for any object or array that's embedded, it will create a key value pair in the map that's returned. It keeps the nesting in place so the is still a context to e.g. determine type (array of stings).
func NewGenerateAPIReferenceCommand ¶
func NewGenerateAPIReferenceCommand(streams genericclioptions.IOStreams) *cobra.Command
Types ¶
type GenerateAPIRefsOptions ¶
type GenerateAPIRefsOptions struct { CustomResourceDefinitionPaths []string TemplatesDir string OutputDir string Overwrite bool }
func NewGenerateAPIRefsOptions ¶
func NewGenerateAPIRefsOptions() *GenerateAPIRefsOptions
func (*GenerateAPIRefsOptions) AddFlags ¶
func (o *GenerateAPIRefsOptions) AddFlags(cmd *cobra.Command)
func (*GenerateAPIRefsOptions) Complete ¶
func (o *GenerateAPIRefsOptions) Complete(args []string) error
func (*GenerateAPIRefsOptions) Run ¶
func (o *GenerateAPIRefsOptions) Run(streams genericclioptions.IOStreams, cmd *cobra.Command) error
func (*GenerateAPIRefsOptions) Validate ¶
func (o *GenerateAPIRefsOptions) Validate(args []string) error
type ResourceInfo ¶
type ResourceInfo struct { APIVersion string Group string Version string Names apiextensionsv1.CustomResourceDefinitionNames Scope apiextensionsv1.ResourceScope Served bool Storage bool Property apiextensionsv1.JSONSchemaProps NestedProperties map[string]apiextensionsv1.JSONSchemaProps }
Click to show internal directories.
Click to hide internal directories.