-
Notifications
You must be signed in to change notification settings - Fork 264
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
Functionality without specifying yaml.schemas #15
Comments
It doesn't do any automatic querying to http://schemastore.org/json/ nor does it support $schema afaik but if there is a use case there we might be able to add it. Currently when you don't insert a schema via yaml.schemas the only features are document outlining and regular yaml validation |
I think it would be awesome to use that. Many applications like ESLint support both JSON and YAML for their config file and that would allow to use the JSON schema that is available in schemastore automatically for .eslintrc.yml files just like VS Code does for .eslintrc.json files. |
I think we already have the basis for that in https://github.com/redhat-developer/vscode-yaml/blob/9fdaa7f62f336def2d425f33ff6599db09c80f28/src/extension.ts#L66 If i'm understanding correctly but we haven't set up any files with it yet. If thats what you're looking for I can definitely add that to the to-do list |
Not sure what you mean with "haven't set up any files with it yet". JSON schema store has an API that returns URLs of schemas and glob patterns they should apply to: http://schemastore.org/api/json/catalog.json |
I just contributed a .travis.yml schema to JSON schema store: SchemaStore/schemastore#368 🎉 I think that's the first YAML-only schema so far, so their maintainers definitely seem to be open to use it for YAML |
This is what I was thinking of when I said I haven't set any files up yet: https://code.visualstudio.com/docs/extensionAPI/extension-points#_contributesjsonvalidation. We have a similar property called yamlValidation (https://github.com/redhat-developer/vscode-yaml/blob/master/package.json#L35) that behaves the same way and allows us to setup schemas for specific files |
it would be best if this extension just queried the schema store API to find a schema to use |
Great news! This should be in our next release! |
I just have a quick question about the travis schema and appveyor schema, I was wondering if you wrote those yourself or if they were generated? We found one small thing with appveyor and then it looks like a few fields are missing in the travis one noted here redhat-developer/vscode-yaml#47 |
Yeah, I just wrote it myself from digging through the documentation. It's definitely not perfect, I noticed things that can be improved myself. |
I'm definitely going to see if theres anything that I can personally add to it to make it better! |
Added in 0.0.7! |
I was wondering how good the support is when not specifying
yaml.schemas
?Does it automatically query schemas from http://schemastore.org/json/?
Does it support
$schema
?The text was updated successfully, but these errors were encountered: