Implement JSON Schema for PGXN Meta Spec v1 #3
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Based on the descriptions in
spec.md
and the validation in pgxn/pgxn-meta-validator, write JSON Schema v2020 schemas to validate PGXN Meta SpecMETA.json
files. The implementation should be at least as good as the old one, now portable for use in other languages.In the process, correct a few issues and errors discovered in
spec.md
and increment its version to v1.0.2.Add a test suite in Rust that uses the boon crate to verify that the schemas, their IDs, and their examples are valid. This sets the stage for writing a validation utility in Rust.
To keep things tidy and somewhat standardized, add a pre-commit configuration to lint the JSON and Rust code.
Then setup a GitHub workflow to run the tests on macOS, Windows, and Linux, and the pre-commit linting on Linux. Overkill for now, since there is no Rust library, just tests for the JSON Schema, but likely to be needed before long.