feat: add cli first class validation (#8374)

* feat: add cli first class validation
* feat: add required flag to cli options
* Add unit test to catch invalid and missing flag
This commit is contained in:
Steven Masley
2023-07-11 09:59:55 -04:00
committed by GitHub
parent 3f6a158016
commit bc102d6bd7
10 changed files with 186 additions and 32 deletions

4
coderd/apidoc/docs.go generated
View File

@ -6239,6 +6239,10 @@ const docTemplate = `{
"name": {
"type": "string"
},
"required": {
"description": "Required means this value must be set by some means. It requires\n` + "`" + `ValueSource != ValueSourceNone` + "`" + `\nIf ` + "`" + `Default` + "`" + ` is set, then ` + "`" + `Required` + "`" + ` is ignored.",
"type": "boolean"
},
"use_instead": {
"description": "UseInstead is a list of options that should be used instead of this one.\nThe field is used to generate a deprecation warning.",
"type": "array",