From 160113d411dfdbcef50ead1d341b2221fd3d6544 Mon Sep 17 00:00:00 2001 From: Jorge Marques Date: Fri, 29 Nov 2024 18:27:00 -0300 Subject: [PATCH] cli: author-mode: Fix make clean and touch source Good side-effect: will also trigger a full rebuild. Signed-off-by: Jorge Marques --- adi_doctools/cli/author_mode.py | 4 ++++ docs/cli.rst | 6 +----- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/adi_doctools/cli/author_mode.py b/adi_doctools/cli/author_mode.py index d31cecd..5593bc0 100644 --- a/adi_doctools/cli/author_mode.py +++ b/adi_doctools/cli/author_mode.py @@ -395,6 +395,10 @@ def check_files(scheduler): update_page = True watch_file_src[file] = ctime + if not path.isdir(builddir): + # User did make clean + update_sphinx = True + if first_run is True: first_run = False update_page = False diff --git a/docs/cli.rst b/docs/cli.rst index d11dc63..e3194fa 100644 --- a/docs/cli.rst +++ b/docs/cli.rst @@ -50,11 +50,7 @@ All options can be listed with: How can I rebuild the whole documentation within Author Mode? ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ -Run ``make clean`` in another tab and then touch any file, for example: - -.. shell:: - - $make clean ; touch conf.rst +Run ``make clean`` in another tab, it will trigger a full rebuild. Do **not** do ``make clean html`` since it will generate a build without the proper Author Mode environment and live reload won't work properly.