Ok guys, maybe this one has been asked before, but I searched and ran threw nothing, so i'm taking a chance here.
I'm using the latest vim (gvim 7.3), on Windows 7 64bits.
I've got some remote files that I want to edit directly with vim, using netrw.
Right now, I've got a fully working transparent ssh connexion to my remote hosts, thanks to Putty, Pageant and public/private keys.
I've successfully setup a read/write access to distant files with those fixes:
#### .vimrc ####
let g:netrw_cygwin= 0
let g:netrw_scp_cmd = 'c:\"Program Files (x86)"\PuTTY\pscp.exe -q -batch'
let g:netrw_sftp_cmd= '"c:\"Program Files (x86)"\PuTTY\psftp.exe'
Then I can access a file with :
:e scp:\\user@host:port\\home\me\some-file.txt
And, each time I access remote file, Vim run a windows prompt (cmd.exe) :
C:\Windows\system32\cmd.exe /c c:\"Program Files (x86)"\PuTTY\pscp.exe -q -batch
-P 22 "C:\Users\me\AppData\Local\Temp\VIF215E.tmp" "user@host:/home/me/some-file.txt"
Hit any key to close this window...
My problem is that hitting a key outside Vim each time I want to open/write a file isn't efficient at all.
So my question(s) is(are) :
- Am I doing it the right way ?
- Is there another way of transparently accessing a remote file with ssh on Windows ?
- If no, is there a way to get rid of "Hit any key to close this window..." when Vim launches putty's pscp.exe ?
Thanks a lot and happy vimming.