Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

remove mixed enum from devContainer.base.schema.json #223

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 9 additions & 11 deletions schemas/devContainer.base.schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -413,16 +413,14 @@
"gpu": {
"oneOf": [
{
"type": [
"boolean",
"string"
],
"enum": [
true,
false,
"optional"
],
"description": "Indicates whether a GPU is required. The string \"optional\" indicates that a GPU is optional. An object value can be used to configure more detailed requirements."
"type": "boolean",
"const" : true,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is false still a valid value with this?

"description": "Indicates a GPU is required."
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The description can be shown in editors. I suggest we copy the original description to both descriptions here, so the user will always get the full description for all 3 cases.

},
{
"type": "string",
"const": "optional",
"description": "\"optional\" indicates that a GPU is optional."
},
{
"type": "object",
Expand Down Expand Up @@ -723,4 +721,4 @@
}
],
"unevaluatedProperties": false
}

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ok

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ok

}