I am still suck at vim or emacs. I use nano to edit files on remote machines. But for more complicated editing, I prefer to use sublime.
use this
https://github.com/randy3k/RemoteSubl for editing remote files.
Steps:
on remote machine, install rmate ssh bio1 curl -o ~/bin/rmate
https://raw.githubusercontent.com/aurora/rmate/master/rmate chmod u+x bin/rmate on your local computer, install RemoteSubl on your local computer, open sublime, click tools –> Command Palette –> type Package control:Install Package –> type RemoteSubl to install.