Monday, December 3, 2012

Re: how to execute ranger from gvim

what's the problem with just :!ranger  ?

On 08/09/2012 06:02 AM, Sepp Tannhuber wrote:
I use the following function from the ranger manual:  fun! RangerChooser()  exec "silent !ranger --choosefile=/tmp/chosenfile" . expand("%:p:h")  if filereadable('/tmp/chosenfile')  exec 'edit ' . system('cat /tmp/chosenfile')  call system('rm /tmp/chosenfile')  endif  redraw!  endfun  map ,r :call RangerChooser()<CR>

No comments:

Post a Comment