Use preview-window for search results
This commit is contained in:
parent
d6af83b9fa
commit
8c0b12d556
@ -5,12 +5,10 @@ func! vundle#scripts#search(bang,search_str)
|
|||||||
endf
|
endf
|
||||||
|
|
||||||
func! s:display(results,search_str)
|
func! s:display(results,search_str)
|
||||||
if !exists('s:buff')
|
if !exists('s:buff') | let s:buff = tempname() | endif
|
||||||
let s:buff = tempname()
|
|
||||||
split
|
|
||||||
endif
|
|
||||||
call writefile(['" Search results for: '.a:search_str] + a:results, s:buff)
|
call writefile(['" Search results for: '.a:search_str] + a:results, s:buff)
|
||||||
exec 'e '.s:buff
|
pedit `=s:buff`
|
||||||
|
wincmd P
|
||||||
let @/=a:search_str
|
let @/=a:search_str
|
||||||
setlocal hls ft=vim
|
setlocal hls ft=vim
|
||||||
redraw
|
redraw
|
||||||
|
Loading…
Reference in New Issue
Block a user