Add to the top of devenv.yaml
:
# yaml-language-server: $schema=<url/path to devenv.schema.json>
{ | |
"$id": "https://example.com/devenv.schema.json", | |
"$schema": "https://json-schema.org/draft/2020-12/schema", | |
"title": "devenv.yaml schema", | |
"type": "object", | |
"properties": { | |
"inputs": { | |
"type": "object", | |
"description": "The Nix flake inputs to use.", | |
"additionalProperties": { | |
"type": "object", | |
"properties": { | |
"url": { | |
"type": "string", | |
"description": "The URL for the input.\nFor example:\n\n- github:NixOS/nixpkgs/nixpkgs-unstable\n- path:./relative/path/to/a/flake\n- git+https://git.somehost.tld/user/path?ref=branch&rev=fdc8ef970de2b4634e1b3dca296e1ed918459a9e" | |
}, | |
"overlays": { | |
"type": "array", | |
"items": { | |
"type": "string", | |
"description": "Which overlay names to use from the input." | |
} | |
}, | |
"inputs": { | |
"type": "object", | |
"additionalProperties": { | |
"type": "object", | |
"properties": { | |
"follows": { | |
"type": "string", | |
"description": "The top-level input from this devenv.yaml to replace this input with." | |
} | |
} | |
} | |
} | |
} | |
} | |
}, | |
"allowUnfree": { | |
"type": "boolean", | |
"description": "Whether to allow unfree packages in nixpkgs." | |
}, | |
"imports": { | |
"type": "array", | |
"items": { | |
"type": "string", | |
"description": "Which directories (containing devenv.nix) to import." | |
} | |
} | |
}, | |
"additionalProperties": false | |
} |