docs: raise exception if dint reports an error
Currently, even if dint fails for some reason, the documentation generation continues on. This is not good as it hides problems until someone manually discovers them. Fix this by checking the exit code of dint and raising an exception if it isn't zero. To facilitate this, also replace call() with run() since it's a more modern and more flexible API. Signed-off-by: Stefan Hansson <newbyte@postmarketos.org> Part-of: <https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/7982>
This commit is contained in:
+1
-1
@@ -29,7 +29,7 @@ html_title = "postmarketOS Packaging"
|
||||
|
||||
def run_dint_doc(app):
|
||||
with Path(__file__).parent.joinpath("deviceinfo-reference.md").open("w") as f:
|
||||
subprocess.call(["dint", "doc"], stdout=f)
|
||||
subprocess.run(["dint", "doc"], stdout=f, check=True)
|
||||
|
||||
|
||||
def setup(app):
|
||||
|
||||
Reference in New Issue
Block a user