File tree Expand file tree Collapse file tree 1 file changed +7
-9
lines changed Expand file tree Collapse file tree 1 file changed +7
-9
lines changed Original file line number Diff line number Diff line change @@ -5,23 +5,21 @@ let b:did_ftplugin = 1
55
66function ! s: reload_log () abort
77 if &buftype == ' quickfix' && get (w: , ' quickfix_title' ) = ~ ' ^:cgetfile'
8- let pos = getpos ( ' . ' )
9- exe ' cgetfile ' exists (' *fnameescape' ) ? fnameescape (w: quickfix_title [10 :-1 ]) : w: quickfix_title [10 :-1 ]
10- call setpos (' .' , pos)
8+ let cmd = ' cgetfile ' .
9+ \ ( exists (' *fnameescape' ) ? fnameescape (w: quickfix_title [10 :-1 ]) : w: quickfix_title [10 :-1 ]) .
10+ \ " | call setpos('.', " . string ( getpos ( ' . ' )) . " ) "
1111 else
12- checktime
13- endif
14- if &l: filetype !=# ' railslog'
15- setfiletype railslog
12+ let cmd = ' checktime'
1613 endif
14+ return cmd . " |if &l:filetype !=# 'railslog'|setfiletype railslog|endif"
1715endfunction
1816
1917if exists (' w:quickfix_title' )
2018 runtime ! ftplugin/qf.vim ftplugin/ qf_* .vim ftplugin/qf/ * .vim
2119endif
2220let b: undo_ftplugin = get (b: , ' undo_ftplugin' , ' exe' )
23- nnoremap <buffer> <silent> R :<C-U> call <SID> reload_log()<CR>
24- nnoremap <buffer> <silent> G :<C-U> call <SID> reload_log()<Bar> exe v:count ? v:count : '$'<CR>
21+ nnoremap <buffer> <silent> R :<C-U> exe <SID> reload_log()<CR>
22+ nnoremap <buffer> <silent> G :<C-U> exe <SID> reload_log()<Bar> exe v:count ? v:count : '$'<CR>
2523nnoremap <buffer> <silent> q :bwipe<CR>
2624let b: undo_ftplugin .= ' |sil! nunmap <buffer> R|sil! nunmap <buffer> G|sil! nunmap <buffer> q'
2725setlocal noswapfile autoread
You can’t perform that action at this time.
0 commit comments