From 157dab33a85b730da29fdc408d3b26d6bc694ba4 Mon Sep 17 00:00:00 2001 From: Florian Albrechtskirchinger Date: Tue, 26 Jul 2022 12:26:32 +0200 Subject: [PATCH] docset: add list_removed_paths make target --- docs/docset/Makefile | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/docs/docset/Makefile b/docs/docset/Makefile index 9f432125d..38121a9e8 100644 --- a/docs/docset/Makefile +++ b/docs/docset/Makefile @@ -44,6 +44,23 @@ list_missing_pages: docSet.dsidx fi \ done +# list paths in the docset index without a corresponding mkdocs page +.PHONY: list_removed_paths +list_removed_paths: docSet.dsidx + @for path in $$(sqlite3 docSet.dsidx "SELECT path FROM searchIndex"); do \ + page=$${path/\/index.html/.md}; \ + page_index=$${path/index.html/index.md}; \ + page_found=0; \ + for p in $(MKDOCS_PAGES); do \ + if [ "x$$p" = "x$$page" -o "x$$p" = "x$$page_index" ]; then \ + page_found=1; \ + fi \ + done; \ + if [ "x$$page_found" = "x0" ]; then \ + echo $$path; \ + fi \ + done + .PHONY: clean clean: rm -f docSet.dsidx