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:
Stefan Hansson
2026-02-11 01:01:45 +00:00
parent f859fe7ad0
commit d6834e89f3
+1 -1
View File
@@ -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):