Mercurial > vim-gutentags
comparison autoload/gutentags.vim @ 221:93c492ed3d62
Add support for using `:verbose` with `:GutentagsUpdate`.
author | Ludovic Chabant <ludovic@chabant.com> |
---|---|
date | Sat, 03 Nov 2018 23:56:50 -0700 |
parents | 60229a0ea17d |
children | c64e8847b4e1 |
comparison
equal
deleted
inserted
replaced
220:60229a0ea17d | 221:93c492ed3d62 |
---|---|
418 | 418 |
419 " Tags File Management {{{ | 419 " Tags File Management {{{ |
420 | 420 |
421 " (Re)Generate the tags file for the current buffer's file. | 421 " (Re)Generate the tags file for the current buffer's file. |
422 function! s:manual_update_tags(bang) abort | 422 function! s:manual_update_tags(bang) abort |
423 let l:bn = bufnr('%') | 423 let l:restore_prev_trace = 0 |
424 for module in g:gutentags_modules | 424 let l:prev_trace = g:gutentags_trace |
425 call s:update_tags(l:bn, module, a:bang, 0) | 425 if &verbose > 0 |
426 endfor | 426 let g:gutentags_trace = 1 |
427 silent doautocmd User GutentagsUpdating | 427 let l:restore_prev_trace = 1 |
428 endif | |
429 | |
430 try | |
431 let l:bn = bufnr('%') | |
432 for module in g:gutentags_modules | |
433 call s:update_tags(l:bn, module, a:bang, 0) | |
434 endfor | |
435 silent doautocmd User GutentagsUpdating | |
436 finally | |
437 if l:restore_prev_trace | |
438 let g:gutentags_trace = l:prev_trace | |
439 endif | |
440 endtry | |
428 endfunction | 441 endfunction |
429 | 442 |
430 " (Re)Generate the tags file for a buffer that just go saved. | 443 " (Re)Generate the tags file for a buffer that just go saved. |
431 function! s:write_triggered_update_tags(bufno) abort | 444 function! s:write_triggered_update_tags(bufno) abort |
432 if g:gutentags_enabled && g:gutentags_generate_on_write | 445 if g:gutentags_enabled && g:gutentags_generate_on_write |