News for hackers. Stuff that matters.
Re:You might not need tmux by mike-cardwell on Friday August 01, 2025 @07:14AM (#44755297)
I use a combination of mosh and screen for this. I only need to type something to get my session back, after a reboot. Changing networks or putting my laptop to sleep for days doesn't drop my sessions: https://www.grepular.com/Immortal_SSH_Sessions
Re:You might not need tmux by ghkbrew on Friday August 01, 2025 @01:55PM (#44760101)
Mosh looks very cool, though I've never used it. Does Screen provide some advantage over tmux in this setup?
Re:You might not need tmux by jvanderbot on Friday August 01, 2025 @03:14PM (#44761124)
Yes. Mosh is a seamless replacement for ssh, and screen is a mostly seamless replacement for tmux. One more level is Mosh+byobu, which is so useful I don't even bother with plain terminals most the time.
Re:You might not need tmux by positr0n on Friday August 01, 2025 @03:22PM (#44761225)
Haha I think you have the history backwards here. Tmux was created as a replacement for screen when it was 20 years old! Speaking as someone with ‘set -g prefix c-a’ in their .tmux.conf because my muscle memory is so used to the screen hotkeys.

GNU screen was released in 1987.

tmux was created in 2007.

Re:You might not need tmux by jvanderbot on Friday August 01, 2025 @09:07PM (#44764117)
Hey maybe I do! Great to learn the history here. Regardless, my point is that Byobu is very nice compared to either. That may now be lost due to my careless comment.
Re:You might not need tmux by saagarjha on Saturday August 02, 2025 @05:12AM (#44765934)
It's seamless until you want to scroll.
Re:You might not need tmux by lostdog on Friday August 01, 2025 @05:51PM (#44762868)
Mosh does not support OSC52, so it's a barrier to getting copy/paste to work.
Re:You might not need tmux by kzrdude on Friday August 01, 2025 @07:37PM (#44763587)
And case in point, mosh is another terminal layer, it's also a multiplexer of sorts.

I've used mosh a lot but it's just interesting to note it's in the same category as screen and tmux

Re:You might not need tmux by brontitall on Friday August 01, 2025 @06:16PM (#44763068)
On mobile so I’m not sure which case OSC52 applies to, but I use mosh+tmux 8-10 hours a day. Both bracketed paste and tmux selection setting local clipboard work fine
Re:You might not need tmux by attentive on Saturday August 02, 2025 @03:54AM (#44765610)
it sort of does support it, except it doesn't work with tmux.
Re:You might not need tmux by radiofreeeuropa on Friday August 01, 2025 @06:04PM (#44762957)
Mosh is excellent. It lets remote sessions survive (well, automatically and transparently recover from) disruption that reliably kills ssh.

I basically don't use ssh at all any more for interactive sessions, because I'm sick of a few lost packets on wifi or a weak cell signal dropping my connections and forcing me to start over.

Tmux, I used to use and eventually abandoned. I decided I didn't need two keyboard-based window managers (I use Spectacle on Mac) and the one that was only for shells was the one that could go. I have replaced it with nothing, so far, aside from that I just open more Terminal.app windows now (I also used to use iTerm2, for years, until it dawned on me that I was using exactly nothing in it that's not also provided by Terminal.app, and the latter's got better input latency, so I was suffering an extra installed program and slightly less responsive typing for no reason at all)

Re:You might not need tmux by nyarlathotep_ on Friday August 01, 2025 @07:07PM (#44763426)
Mosh is incredibly useful. I have sessions running from uptime until reboot with machines (pis and a desktop) on my local network from my laptop.

I leave with the laptop, return days later, and perform no manual intervention to reconnect. It's absolutely brilliant.

Re:You might not need tmux by anthk on Saturday August 02, 2025 @03:03AM (#44765396)
I used mosh when my data plan plumetted to 2.7 KBPS (~ISDN/2G speeds).

I connected to a public Unix server and read news, IRC'ed, IM'ed and such like crazy. Also, without being connected to a Pubnix, IRC and Gopher did it fine, the web with patience, and the same with Gemini (gemini://gemi.dev has been really useful to read news and scrap a 95% of unneeded scripts and trackers from web sites).

Usenet was slow on fetching, but totally readable the next morning, and, better, offline.

Re:You might not need tmux by sintax on Saturday August 02, 2025 @09:20AM (#44767385)
Other options for resumable sessions: tmux/screen + https://eternalterminal.dev/ or https://wezterm.org/ which can resume open windows like you get with iTerm2+tmux.