Skip to content

Schema Validation & IDE Setup

UDS CLI ships with JSON schemas for its configuration files. Setting up schema validation in your IDE enables autocompletion and inline validation.

Add a yaml-language-server header comment to your file:

uds-bundle.yaml

# yaml-language-server: $schema=https://raw.githubusercontent.com/defenseunicorns/uds-cli/main/uds.schema.json

zarf.yaml

# yaml-language-server: $schema=https://raw.githubusercontent.com/defenseunicorns/uds-cli/main/zarf.schema.json

tasks.yaml

# yaml-language-server: $schema=https://raw.githubusercontent.com/defenseunicorns/uds-cli/main/tasks.schema.json

This works with both VS Code and GoLand (JetBrains IDEs).

Install the YAML Extension and add the following to your settings.json (pin main to your UDS CLI version if desired):

"yaml.schemas": {
"https://raw.githubusercontent.com/defenseunicorns/uds-cli/main/uds.schema.json": "uds-bundle.yaml"
}

To apply the schema globally without modifying individual files, open Settings → Languages & Frameworks → Schemas and DTDs → JSON Schema Mappings and add a new entry using the schema URL and a file path pattern.