glimpse/plugin/glimpse.vim
branchvim-stuff
changeset 4 4ffc0380b228
parent 1 fd505fd00e63
child 10 a8f9271a7cab
equal deleted inserted replaced
3:db3e3abfc647 4:4ffc0380b228
    86 	let l:orig_errorformat = &errorformat
    86 	let l:orig_errorformat = &errorformat
    87 	execute 'set errorformat=' . escape( g:glimpseErrorFormat, ' ' )
    87 	execute 'set errorformat=' . escape( g:glimpseErrorFormat, ' ' )
    88 
    88 
    89 	" execute the search.
    89 	" execute the search.
    90 	"
    90 	"
    91 	let l:cmd = "glimpse " . g:glimpseFlags . " -F '" . l:cwd . ";" . l:file_pattern . "' '" . l:search_pattern . "'"
    91 	let l:cmd = "glimpse " . g:glimpseFlags . " -F '" . l:cwd
       
    92 	if ( l:file_pattern != '' )
       
    93 		let l:cmd = l:cmd . ";" . l:file_pattern
       
    94 	endif
       
    95 	let l:cmd = l:cmd . "' '" . l:search_pattern . "'"
       
    96 
    92 	let l:result_list = split( system( l:cmd ), "\n" )
    97 	let l:result_list = split( system( l:cmd ), "\n" )
    93 
    98 
    94 	" no results, escape now
    99 	" no results, escape now
    95 	"
   100 	"
    96 	if ( empty(l:result_list) )
   101 	if ( empty(l:result_list) )