-
Notifications
You must be signed in to change notification settings - Fork 9
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
Is there a schema? #57
Comments
Hey ! So i've made the file that you have linked in a format i've created and temporarily named
However, this yet-another-format is not okh specific, i designed it to be usable for any web form description, and already started to use it on another test page for okw. You can also check this test file which i used for front-end development. The file is parsed by this python parser and generates without any other modification the form of this page. The goal was that it is easy to update the form by just pushing a modification to the okhdf file. |
thanks pierre! :-) I do like the compactness of the format, and apart from the In practice though, I need a JSON schema. it would be good if your python script could generate that, because.. any other way of doing it we can not ensure the two formats contents stay consistent. alternatively .. is there a sample YAML file that contains all the attributes? As from that, I could generate a JSON schema with a tool, which I just need to fixup here and there. |
You can find the pseudo-yaml standard here, not sure if it's up-to-date though as we're still organizing the work and platforms : https://app.standardsrepo.com/MakerNetAlliance/OpenKnowHow/src/branch/master/1#8abddfbb-8a84-4ca6-be02-0deeee654487 |
Thanks a lot Piere! :-) Apart from validating, these JSON Schemas also allow to generate sample files. Where/in which repo should I make a pull request for adding the schema? |
For now, for our own purposes, I hosted it here: https://github.com/OPEN-NEXT/LOSH-OKH-tool/blob/master/src/okh-v1.schema.json If we would register this on http://schemastore.org, It would automatically be available in editors and IDEs (like VSCodium, Atom and co.), and people editing their It would make more sense to host in in one of your repos, though. |
I saw in an other issue, that @pciavald mentioned:
https://git.iostud.io/makernet/iop-cdb/-/blob/dev/server/assets/okh.okhdf
That is quite good! :-)
Does it follow a more widely used standard of schemas? I imagine not, as it has a custom ending that looks OKH specific.
Have you though about using http://json-schema.org? I read it can be used for YAML as well.
I am also thinking about using it for OKH LOSH-v1, which we are working on. Could make sense if we use the same thing, and as we use TOML files, which are also supported by JSON-schema .. it could make conversion more standardized/clear. (We are also working on conversion)
The text was updated successfully, but these errors were encountered: