From b261d23876dc2deed218be939a6e6d0ff8fe8deb Mon Sep 17 00:00:00 2001 From: Kenneth Moreland Date: Tue, 24 Oct 2023 14:49:01 +1100 Subject: [PATCH 1/2] Allow turning off todo notes in user's guide --- .gitlab/ci/config/initial_config.cmake | 1 + docs/users-guide/CMakeLists.txt | 9 +++++++++ docs/users-guide/conf.py | 2 +- docs/users-guide/index.rst | 2 -- 4 files changed, 11 insertions(+), 3 deletions(-) diff --git a/.gitlab/ci/config/initial_config.cmake b/.gitlab/ci/config/initial_config.cmake index 923f51159..05f4d0482 100644 --- a/.gitlab/ci/config/initial_config.cmake +++ b/.gitlab/ci/config/initial_config.cmake @@ -66,6 +66,7 @@ foreach(option IN LISTS options) elseif(docs STREQUAL option) set(VTKm_ENABLE_DOCUMENTATION "ON" CACHE STRING "") + set(VTKm_USERS_GUIDE_INCLUDE_TODOS "OFF" CACHE STRING "") elseif(benchmarks STREQUAL option) set(VTKm_ENABLE_BENCHMARKS "ON" CACHE STRING "") diff --git a/docs/users-guide/CMakeLists.txt b/docs/users-guide/CMakeLists.txt index 0bfa47578..73f3b5bed 100644 --- a/docs/users-guide/CMakeLists.txt +++ b/docs/users-guide/CMakeLists.txt @@ -25,9 +25,18 @@ if (NOT Sphinx_FOUND) "Could not find Sphinx to build User's Guide. If you want to compile Doxygen without the User's Guide, turn off VTKm_ENABLE_USERS_GUIDE.") endif() +option(VTKm_USERS_GUIDE_INCLUDE_TODOS + "When building the VTK-m User's Guide, specify whether to include TODO notes." ON) +mark_as_advanced(VTKm_USERS_GUIDE_INCLUDE_TODOS) + # Configuration used in conf.py. set(doxygen_xml_output_dir "${VTKm_BINARY_DIR}/docs/doxygen/xml") set(example_directory "${CMAKE_CURRENT_SOURCE_DIR}/examples") +if(VTKm_USERS_GUIDE_INCLUDE_TODOS) + set(include_todos "True") +else() + set(include_todos "False") +endif() sphinx_add_docs(VTKmUsersGuideHTML BUILDER html diff --git a/docs/users-guide/conf.py b/docs/users-guide/conf.py index b35efeb38..2b31ec90b 100644 --- a/docs/users-guide/conf.py +++ b/docs/users-guide/conf.py @@ -52,7 +52,7 @@ extensions = [ ] # Note: there are some custom extensions at the bottom of this file. -todo_include_todos = True +todo_include_todos = @include_todos@ numfig = True autosectionlabel_prefix_document = True diff --git a/docs/users-guide/index.rst b/docs/users-guide/index.rst index 6e481ee1c..fbf29810f 100644 --- a/docs/users-guide/index.rst +++ b/docs/users-guide/index.rst @@ -4,8 +4,6 @@ The VTK-m User's Guide ============================== -.. todo:: Hide TODOs for release documentation. - | **The VTK-m User's Guide** | Version |version| From 39aa256bb01eaff920dfc29ae02c52eed6374e35 Mon Sep 17 00:00:00 2001 From: Vicente Adolfo Bolea Sanchez Date: Tue, 24 Oct 2023 10:35:06 -0400 Subject: [PATCH 2/2] docs: edit .readthedocs.yaml --- .readthedocs.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.readthedocs.yaml b/.readthedocs.yaml index fe962aa82..109b571ba 100644 --- a/.readthedocs.yaml +++ b/.readthedocs.yaml @@ -27,7 +27,7 @@ build: - git lfs install --local - git lfs fetch --include "*.png" - git lfs checkout *.png - - cmake -B build -S . -DVTKm_ENABLE_DOCUMENTATION=ON -DVTKm_ENABLE_USERS_GUIDE=ON + - cmake -B build -S . -DVTKm_ENABLE_DOCUMENTATION=ON -DVTKm_ENABLE_USERS_GUIDE=ON -DVTKm_USERS_GUIDE_INCLUDE_TODOS=OFF - cmake --build build --target VTKmDoxygenDocs - cp -f ./build/docs/users-guide/VTKmUsersGuideHTML.cache/conf.py docs/users-guide/conf.py