Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func MarshalJSON ¶
func MarshalJSON(doc *SchemaDocument) ([]byte, error)
MarshalJSON returns a stable, indented JSON encoding of the schema document.
Types ¶
type ConfigEntry ¶
type ConfigEntry struct {
Env string `json:"env"`
Field string `json:"field"`
Type string `json:"type"`
DefaultValue string `json:"defaultValue,omitempty"`
Description string `json:"description,omitempty"`
Options []string `json:"options,omitempty"`
SupportsFile bool `json:"supportsFile,omitempty"`
Conditional bool `json:"conditional,omitempty"`
BuildTags []string `json:"buildTags,omitempty"`
Source string `json:"source"`
SourceFile string `json:"sourceFile"`
SourceSymbol string `json:"sourceSymbol"`
}
ConfigEntry describes an environment-backed runtime config value.
type SchemaDocument ¶
type SchemaDocument struct {
SchemaVersion int `json:"schemaVersion"`
Notes []string `json:"notes,omitempty"`
EnvConfig []ConfigEntry `json:"envConfig"`
SettingEnvOverrides []SettingOverrideEntry `json:"settingEnvOverrides"`
}
SchemaDocument is the canonical JSON artifact consumed by the docs site.
func GenerateWithSourceRoot ¶
func GenerateWithSourceRoot(sourceRoot string) (*SchemaDocument, error)
GenerateWithSourceRoot builds the canonical schema document for config and settings docs.
type SettingOverrideEntry ¶
type SettingOverrideEntry struct {
Env string `json:"env"`
SettingKey string `json:"settingKey"`
Description string `json:"description,omitempty"`
DefaultValue string `json:"defaultValue,omitempty"`
Type string `json:"type"`
Sensitive bool `json:"sensitive"`
Deprecated bool `json:"deprecated"`
Category string `json:"category,omitempty"`
Public bool `json:"public"`
Requires string `json:"requires,omitempty"`
Note string `json:"note,omitempty"`
Source string `json:"source"`
SourceFile string `json:"sourceFile"`
SourceSymbol string `json:"sourceSymbol"`
}
SettingOverrideEntry describes a database-backed setting that can be controlled by env vars.
Click to show internal directories.
Click to hide internal directories.