Tuesday, September 2, 2008

Emacs, TRAMP

TRAMP is an emacs extension that lets you edit remote files via ssh.  This is nifty because it lets you have your own .emacs almost regardless of what you're editing. 

Installation/use on Ubuntu is a snap:

sudo apt-get install tramp

add the following line to your .emacs (in your home directory)

(setq tramp-default-method "ssh")

C-x C-f /ssh:user@hostname:/path/to/file

(for whatever random reason, that syntax stopped working for me with no changes to the underlying system that I'm aware of after a week or so of using it.  I got the error "ssh: ssh: Name or service not known" and revised the command to be as follows:

C-x C-f /user@hostname:/path/to/file

)

No comments: