Documentation
¶
Overview ¶
Package configschema generates the JSON Schema for `atmos.yaml` (the Atmos CLI configuration) by reflecting over schema.AtmosConfiguration — the exact struct Atmos decodes `atmos.yaml` into — so the published schema can never drift from the code. Go doc comments on the configuration structs become schema descriptions.
The committed artifact at pkg/datafetcher/schema/atmos/config/1.0.json is regenerated with `go generate ./pkg/config/schema` and guarded by a drift test that fails whenever the configuration structs change without a regeneration. The atmos binary never imports this package; generation happens at development and test time only.
Index ¶
Constants ¶
const ( // SchemaID is the canonical `$id` of the generated schema — the floating // (always-latest) URL published on atmos.tools. Per-release pinned copies are // published under `.../atmos-config/<version>/atmos-config.json`. SchemaID = "https://atmos.tools/schemas/atmos/atmos-config/1.0/atmos-config.json" // EmbeddedSource is the `atmos://` source the embedded copy of the schema is // served from (see pkg/datafetcher). EmbeddedSource = "atmos://schema/atmos/config/1.0" // EmbeddedPath is the repository-relative path of the committed schema // artifact embedded into the binary by pkg/datafetcher. EmbeddedPath = "pkg/datafetcher/schema/atmos/config/1.0.json" )
Variables ¶
var ErrRepoRootNotFound = errors.New("failed to locate the repository root from the configschema source file")
ErrRepoRootNotFound indicates the repository root could not be located from this source file, which means generation is running outside a source checkout.
Functions ¶
Types ¶
This section is empty.