docs.sh: Make the script independent of the working directory

This commit is contained in:
Kamil Śliwak 2022-04-08 20:40:17 +02:00
parent a608bc12f7
commit efd0024853

View File

@ -27,7 +27,9 @@
#------------------------------------------------------------------------------ #------------------------------------------------------------------------------
set -e set -e
cd docs
script_dir="$(dirname "$0")"
cd "${script_dir}"
pip3 install -r requirements.txt --upgrade --upgrade-strategy eager pip3 install -r requirements.txt --upgrade --upgrade-strategy eager
sphinx-build -nW -b html -d _build/doctrees . _build/html sphinx-build -nW -b html -d _build/doctrees . _build/html
cd ..