Skip to content
Snippets Groups Projects
Commit 39ed5c21 authored by Timo Koch's avatar Timo Koch
Browse files

Merge branch 'feature/doxygen-auto-delete-html-folder' into 'master'

[doxygen] Add auto-deletion of the html folder, so that doxygen always builds a new documentation



See merge request !49
parents 1e307085 8eb2ad3c
No related branches found
No related tags found
No related merge requests found
......@@ -4,8 +4,11 @@
MACRO (add_dumux_doxygen_target)
if(DOXYGEN_FOUND)
add_doxygen_target()
add_custom_target(doxygen_${ProjectName}_prebuild
COMMAND rm -rf ${CMAKE_BINARY_DIR}/doc/doxygen/html)
add_dependencies(doxygen_${ProjectName} doxygen_${ProjectName}_prebuild)
add_custom_command(TARGET doxygen_${ProjectName}
POST_BUILD
COMMAND ${CMAKE_SOURCE_DIR}/doc/doxygen/sanitizelinks.sh)
endif()
ENDMACRO (add_dumux_doxygen_target)
ENDMACRO ()
# sanitizes the links to the given lists, because doxygen somehow links
# to a page with a wrong index
function sanitizelinks {
sanitizelinks () {
NEW_FILE=`grep -l "\"title\">$1" html/*html | egrep -o [0-9]+`
OLD_FILE=`awk -v a=$NEW_FILE 'BEGIN {printf("%05d", a-1)}'`
sed -i "s/$OLD_FILE/$NEW_FILE/g" html/*html
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment