Whilst most commandline editors have the ability to edit files on a remote host directly this can get messy sometimes when there are multiple files involved. Mounting the remote folder via SSHFS seems to be more reliable in practical use.
sudo apt-get install sshfs
sudo addgroup USERNAME fuse
sshfs remoteuser@remotehost:/remote/path /local/mountpath
fusermount -u /local/mountpath