From fc6cc575dcec7481800d3e50cbdacef5ad8c5455 Mon Sep 17 00:00:00 2001 From: Marc Balestreri Date: Fri, 28 Nov 2025 09:50:09 -0800 Subject: [PATCH] fix(docs): preserve images across incremental builds Remove `rm -rf _build/html/_images` which deleted images before each build. Sphinx-gallery skips unchanged examples, but cached doctrees prevented image re-copying. Also quote $(GH_PAGES_REPO) for paths with spaces. --- doc/Makefile | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/doc/Makefile b/doc/Makefile index f4192ec..fa4bef9 100644 --- a/doc/Makefile +++ b/doc/Makefile @@ -47,9 +47,6 @@ generate_dynamic_content: python generate.py html: sym_links generate_dynamic_content - # These two lines make the build a bit more lengthy, and the - # the embedding of images more robust - rm -rf $(BUILDDIR)/html/_images $(SPHINXBUILD) -b html $(ALLSPHINXOPTS) $(BUILDDIR)/html touch $(BUILDDIR)/html/.nojekyll @echo @@ -57,5 +54,5 @@ html: sym_links generate_dynamic_content deploy: html # Assuming the docs repo is cloned in the same repo as biolearn is this will update the site - rsync -av --delete --exclude .git/ _build/html/ $(GH_PAGES_REPO) - cd $(GH_PAGES_REPO) && git add . && git commit -m "Automation Updated documentation" && git push \ No newline at end of file + rsync -av --delete --exclude .git/ _build/html/ "$(GH_PAGES_REPO)" + cd "$(GH_PAGES_REPO)" && git add . && git commit -m "Automation Updated documentation" && git push