It isn't very difficult to install vim in your home directory, and I see that you've found a way. However this is not necessarily the best solution.
Running vim on the remote machine has the downsides of running a remote editor: it lags if the connection lags; it dies if the connection dies.
You can use (g)vim locally to edit remote files. There are two approaches for that. One approach is to mount the remote filesystem over sshfs. Sshfs is available on most unices (but not on Windows). Once mounted, you can edit files with Vim and generally manipulate files as if they were local. Sshfs requires SFTP access on the remote machine.
mkdir ~/net/someserver
sshfs someserver:/ ~/net/someserver
gvim ~/net/someserver/path/to/file
fusermount -u ~/net/someserver
Alternatively, you can make Vim do the remote access. The netrw plugin is bundled with Vim.
gvim scp://someserver/path/to/file
A limitation of both approaches is that the files are opened with the permissions of the user that you SSH into. This can be a problem if you need to edit files as root, since SSH servers are often configured to forbid direct root logins over SSH (not so much for security as for accountability — having a trace if a non-malicious root screws up). Vim has a plugin to edit over ssh and a plugin to edit over sudo, but I don't know how to combine the two.
.vimrc
files between N machines. – Evgeni Sergeev Oct 02 '13 at 03:03let g:netrw_cygwin = 0
andlet g:netrw_scp_cmd = "C:\\Programs\\PuTTY\\pscp.exe "
in_vimrc
, which lets me write in Command Promptgvim scp://user@host/file/relative/to/home.txt
, which works great, but it asks for the password on every read and write (doesn't keep alive). I'd rather not store the password in plain text on disk. – Evgeni Sergeev Oct 02 '13 at 03:04~/.ssh/authorized_keys
on the server as a new line, started up Pageant daemon on my Windows machine, added the private key file into it, and now editing using SCP in Vim doesn't ask for a password anymore, but only "press any key to continue". Which makes it usable! (It is also possible to configure WinSCP such that Editing will get Vim to do it.) – Evgeni Sergeev Oct 02 '13 at 07:49gvim.exe
in a file picker and assigning it to handle the editing of all files. – Evgeni Sergeev Oct 03 '13 at 07:03