haystack/.github/utils/code_and_docs.sh
Massimiliano Pippi 8ee2b6b403
Add a custom pydoc renderer for Readme.io (#2825)
* add custom pydoc renderer

* create an example

* revert example code
2022-07-22 10:43:51 +02:00

28 lines
713 B
Bash
Executable File

#!/bin/bash
echo "========== Apply Black ========== "
black .
echo
echo "========== Convert tutorial notebooks into webpages ========== "
python .github/utils/convert_notebooks_into_webpages.py
echo
echo "========== Generate OpenAPI docs ========== "
python .github/utils/generate_openapi_specs.py
echo
echo "========== Generate JSON schema ========== "
python .github/utils/generate_json_schema.py
echo
echo "========== Generate the API documentation ========== "
set -e # Fails on any error in the following loop
export PYTHONPATH=$PWD/docs/pydoc # Make the renderers available to pydoc
cd docs/_src/api/api/
for file in ../pydoc/* ; do
echo "Processing" $file
pydoc-markdown "$file"
done
echo