diff --git a/doc/source/bootstrapdocs.py b/doc/source/bootstrapdocs.py index d3d2b253870a..830071a3cf9e 100644 --- a/doc/source/bootstrapdocs.py +++ b/doc/source/bootstrapdocs.py @@ -1,10 +1,13 @@ import json import os import subprocess +import sys RST_GENERATION_SCRIPT = 'htmlgen' script_path = os.path.join(os.path.dirname(__file__), RST_GENERATION_SCRIPT) os.environ['PATH'] += ':.' -#status = os.spawnlpe(os.P_WAIT, script_path, os.environ) -subprocess.call("python "+script_path, shell=True, env=os.environ) +rc = subprocess.call("python "+ script_path, shell=True, env=os.environ) +if rc != 0: + sys.stderr.write("Failed to generate documentation!\n") + sys.exit(2)