-
Notifications
You must be signed in to change notification settings - Fork 135
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
Generate JSON Schema using shacl2code #893
Conversation
1d529bf
to
4276637
Compare
@licquia Here is the actions to generate the JSON schema. Note that the schema is still incorrect until the model & spec parser are fixed |
4276637
to
14a3932
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @JPEWdev - This will be quite helpful for validation
4627e23
to
2481958
Compare
Generates the JSON schema for validating JSON-LD documents using `shacl2code` Signed-off-by: Joshua Watt <[email protected]>
2481958
to
8f44f11
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
One question, but looks fine
shacl2code generate \ | ||
--input spdx-spec/docs/model/ontology.rdf.ttl \ | ||
--input spdx-spec/docs/model/jsonld-annotations.ttl \ | ||
--context-url spdx-spec/docs/model/context.jsonld https://spdx.org/rdf/3.0.0/spdx-context.jsonld \ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I am confused? why is there an argument before the url?
--context-url spdx-spec/docs/model/context.jsonld https://spdx.org/rdf/3.0.0/spdx-context.jsonld \ | |
--context-url https://spdx.org/rdf/3.0.0/spdx-context.jsonld \ |
Maybe I am just not aware of the API of your tool
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The tool lets you either specify a URL (with --context) or a local file and URL (with --context-url) in which case the data is read from the local file, but the URL is used in the bindings. The later is useful to generate bindings before the URL is published
Generates the JSON schema for validating JSON-LD documents using
shacl2code