python-jsonschema / check-jsonschema

A CLI and set of pre-commit hooks for jsonschema validation with built-in support for GitHub Workflows, Renovate, Azure Pipelines, and more!
https://check-jsonschema.readthedocs.io/en/stable
Other
192 stars 38 forks source link

Add new `--disable-formats` flag to replace `--disable-format` #261

Closed sirosen closed 1 year ago

sirosen commented 1 year ago

--disable-formats "*" will replace --disable-format (deprecated). --disable-formats regex is an alternative to --format-regex disabled, but that usage is not deprecated yet (I'm unusre if it should be). --disable-formats uri-reference --disable-formats email --disable-formats ipv4 is new behavior to disable specific checks.

--disable-format will warn when used, but is still effective.

sirosen commented 1 year ago

Hm. In #231 I wrote this down as a comma-delimited list, and here I implemented it as a multi-use option. Comma-delimited usage would be nicer and I don't like the way that click is rendering a really long list of choices.

sirosen commented 1 year ago

Fixed it by adding comma-delimited-list parsing and allowing that combined with the multi-argument usage.