haystack/.github/utils/generate_json_schema.py
Sara Zan 2d65c380f1
pre-commit hooks (#2819)
* Add pre-commit config

* update contributing guidelines

* try failing the workflow

* add pre-commit to the deps

* updating uninstall instructions

* separate jobs in CI

* make tutorials check fail

* make black check fail

* make openapi check fail

* make yaml schema and api docs checks fail

* highlight the instructions

* Update .pre-commit-config.yaml

Co-authored-by: Tobias Wochinger <mail@tobias-wochinger.de>

* Update CONTRIBUTING.md

Co-authored-by: Tobias Wochinger <mail@tobias-wochinger.de>

* Update CONTRIBUTING.md

Co-authored-by: Tobias Wochinger <mail@tobias-wochinger.de>

* Use black --check

* Add images of the CI

* title level

* feedback

Co-authored-by: Tobias Wochinger <mail@tobias-wochinger.de>
2022-07-26 15:02:15 +02:00

14 lines
302 B
Python
Executable File

#!/usr/bin/env python3
import sys
import logging
from pathlib import Path
logging.basicConfig(level=logging.INFO)
sys.path.append(".")
from haystack.nodes._json_schema import update_json_schema
update_json_schema(destination_path=Path(__file__).parent.parent.parent / "haystack" / "json-schemas")