Utilities/Sphinx: Print path to index.html in build output

Print the url to index.html in the build output, just so one can
"open in browser" from the context menu in some terminals.
This commit is contained in:
Arcturus Arcturus
2021-09-16 12:55:12 +01:00
committed by Brad King
parent 8dee2c3aee
commit 1d03aa841c

View File

@@ -58,6 +58,13 @@ configure_file(conf.py.in conf.py @ONLY)
set(doc_formats "")
if(SPHINX_HTML)
list(APPEND doc_formats html)
# we provide the path to the produced html output in the console
# for tools that support URI protocol schemes
set(html_extra_commands
COMMAND ${CMAKE_COMMAND} -E echo "sphinx-build html: HTML documentation generated in file://${CMAKE_CURRENT_BINARY_DIR}/html/index.html"
)
endif()
if(SPHINX_MAN)
list(APPEND doc_formats man)