Comment by pixard
20 hours ago
I really want to like this. Ideologically I'm on board. Who wouldn't want to avoid all this multiplexing complexity and pitfalls? But deferring the window management to the OS sounds great in theory, but in practice it falls short (at least for me).
I work on both MacOS and Linux. Even if I were to figure out a perfect window management approach, I'd have to do it twice, and then figure out a way to "attach" to a layout of windows essentially. And then make it cross-platform... or live with zero organization, or at best some kind of flat structure. That's a immediate non-starter. Even if I focused only on a single OS, I still don't consider this a viable approach. It would be like removing browser tabs, and saying let's let the OS manage all this nasty UI stuff.
So then the next immediate idea is let's just have the Terminal itself manage UI. Ghostty supports tabs, splits etc. Great. But if I need to restart Ghostty for whatever reason, my entire layout vanishes and I have to set it all up again?
For me tmux is not just about the attach/detach part. A session is a personal "layout" of the workspace I've organically landed on for this task. Maybe it's a few windows with splits. Maybe it's just the single window with or without a split. Maybe it's a more browser-like just X amount of windows (tabs). If/when things get overwhelming I branch off into a new session for one (or more) sub-tasks. Little fzf-based utilities allow for nice fuzzying over sessions and what not. Or maybe you just run the different sessions in actual different physical OS windows. You can mix and match however you feel that day.
So if I'm in project x, working on feature y, and I detach and walk over to my other computer I can SSH over and continue as if nothing at all changed and retain the exact layout of what I was using before. Simultaneously in another physical window (or a tab) I can just switch to another local (or not) session and instantly be mentally in a different context, working on a different project or feature. Or I can SSH into a server and resume a debugging session left (intentionally) open for a while (which may consist of a few splits/windows/what not).
Maybe I'm missing something. I'm curious how your day-to-day workflow looks like. I imagine if I was 100% bound to a single machine, I could make it work with a tiling wm. But even then Ghostty crashes or something else happens and poof your entire work layout is gone and needs to be re-created (even if the individual pieces are safe).
If you do most of your work on a central server and treat your other devices as thin clients, then (afaik) Tmux/Zellij are the way to go – not to mention if you want to multiplayer with colleagues.
(I know Wezterm has remote session multiplexing in beta, but I’d be surprised if you can re-attach from a different machine.)
Lately I’ve been experimenting with embracing the total scriptability of my favorite terminal, Kitty. Its creator is famously outspoken about non-native multiplexers, precisely because of the pitfalls you mentioned and because they hold back the terminal ecosystem.
Couple of recent issues I’ve had: washed-out colors in Claude Code, desktop notifications not passing through, scrollback weirdness, and image protocol mismatches.
I used to treat Zellij as an OS to build my own IDE in. Now it’s Kitty.
I save layouts as a Kitty session. Important limitation: this doesn’t persist running processes. And so enter zmx. Whenever I need a process I can reattach to I wrap it in zmx.
A terminal agent can interact with the kitty cli to create splits and such. I’m still on the fence as to whether that’s safe. Probably not. Also, tmux is likely better represented in the training data. Currently experimenting with running claude inside tmux (multiplexing) inside nono (sandbox).
You might want to give https://github.com/kstenerud/yoloai a try, then.
Runs agents in tmux in sandboxes.
Hard coded harness support... Yuck.
Gondolin is sand boxes done right...
1 reply →
Niri is a perfect window manager approach, in my opinion. I don’t need tmux. Just Niri + Foot (terminal) and it’s perfect for the way my brain works. If you haven’t tried it, I highly recommended it.
Huh. The person you're replying to specifically mentioned they connect to the same tmux session from different computers. Niri is great, but how's it relevant here?