Hacker News new | ask | show | jobs
by spudlyo 1593 days ago
Yes, Emacs can run very well under tmux on a powerful remote host. I do lots of development that way every day at work. It does take some configuration, and it really helps to have a modern terminal emulator (I use iTerm2 on macOS). Here are some unexpected things I have working with tty Emacs under tmux:

* 24-bit color themes[0]

* Hyper key bindings, also bindings like C-., C-;, etc

* Icon(all-the-icons) via alternate non-ascii "icons-in-terminal" font

* Mouse support w/ scroll wheel (xterm-mouse-mode)

* System clipboard integration (OSC-52)

* Very nice in-emacs terminal emulation via vterm

I build my own Emacs on these powerful remote hosts which I've automated with some Ansible scripting, because the OS vendor's Emacs packages are almost always a couple revisions behind. This way I can build in things like support for native compilation, modules (required for vterm) and rip out things I don't want or need like X support, jpeg, png, gif, etc.

As long as your latency via SSH to the remote host is reasonable, in my opinion this is approach is considerably better than what TRAMP offers in terms of speed and ease of use.

[0]: https://muppetlabs.com/~mikeh/ttyemacs.png

1 comments

It's easy to forget this is an option because it's so rarely practical nowadays what with all the bitmap graphics and 3D acceleration requirements for even half-decent performance, but Emacs actually still works fairly well over a remoted XWindows connection. There's a bit of startup slowdown, and sometimes when switching back to it from another window it may take a moment to redraw, but most editing usage is surprisingly good. Of course this depends on latency to the target.

This may be as simple as "ssh -X $TARGET" and running "emacs". You'll know fairly quickly whether it's practical or not.