Disable updating of TOC while in diff mode

This commit is contained in:
EinfachToll 2014-11-12 11:13:14 +01:00
parent 9fa06803d6
commit a3e06e4e8d

View File

@ -1576,6 +1576,10 @@ endfunction " }}}
" a:create == 1: creates or updates TOC in current file
" a:create == 0: update if TOC exists
function! vimwiki#base#table_of_contents(create)
" apparently, Vim behaves strange when files change while in diff mode
if &diff
return
endif
" look for existing TOC
let toc_header = '^\s*'.substitute(g:vimwiki_rxH1_Template, '__Header__',