Skip to content

Commit 9c2fadb

Browse files
committed
Add redrawing
1 parent 8531326 commit 9c2fadb

File tree

1 file changed

+6
-3
lines changed

1 file changed

+6
-3
lines changed

plugin/tags.vim

+6-3
Original file line numberDiff line numberDiff line change
@@ -36,9 +36,9 @@ if !exists('g:vim_tags_gems_tags_command')
3636
let g:vim_tags_gems_tags_command = "!ctags -R -f gems.tags `bundle show --paths` 2>/dev/null &"
3737
endif
3838

39-
command! -nargs=0 TagsGenerate :call s:generate_tags()
39+
command! -nargs=0 TagsGenerate :call s:generate_tags(1)
4040

41-
fun! s:generate_tags()
41+
fun! s:generate_tags(redraw)
4242
silent! exe g:vim_tags_project_tags_command
4343
let gemfile_time = getftime('Gemfile.lock')
4444
if gemfile_time > -1
@@ -52,11 +52,14 @@ fun! s:generate_tags()
5252
set tags += "gems.tags"
5353
endif
5454
endif
55+
if a:redraw
56+
redraw!
57+
endif
5558
endfun
5659

5760
if filereadable('tags')
5861
if g:vim_tags_auto_generate
59-
au BufWritePost * call s:generate_tags()
62+
au BufWritePost * call s:generate_tags(0)
6063
endif
6164
endif
6265

0 commit comments

Comments
 (0)