Hacker News new | ask | show | jobs
by deangiberson 27 days ago
Funny, I started vibing this (https://github.com/deangiberson/emacs-mux) yesterday on the train after playing with cmux for the day and thinking to myself there was nothing that emacs couldn't accomplish.

The repo doesn't quite work yet. Many sharp corners. But the basic idea is there.

pama, I'd be interested in hearing more about how you are using emacs for multiplexing. I'm trying to build up tooling for myself based around file and input workflows and I /really/ don't want to write a text editor and would prefer to stick with emacs.

1 comments

The key idea is to have many differently named shells. Typically, I group them by project (common prefix name), and the projects live in directories. I have some hacks to organize ibuffer, to split frames, to reflow buffers in the existing windows (eg to organize related project buffers (shells, magit, dired), or to show shells from multiple projects, or selected buffers, and so on). Emacs’ natural frame splitting and buffer selecting/switching commands are good enough if you dont display more than four buffers at a time, but soon you may need to show 5, 6, 8, 9, 10, 12, 15, 16, 18, 20, 24 or have funky arrangements, so you may collect functions to help along splitting n*m grids or keeping useful splits. The shells work very organically inside Emacs and you can still use it as a text editor. The so-called “dumb terminal” in M-x shell is a thing of beauty as it really is just a text buffer like any other; I think of it as a bash repl. If you are used to curses TUI commands it may not work, so for these rare occasions I also use eat (but tend to avoid). See also answer to a sibling comment.