News for hackers. Stuff that matters.
Re:How to move a running process into a tmux session (2020) by planede on Wednesday October 05, 2022 @04:17AM (#33092705)
I have an autossh + tmux setup. It's along the lines of

  autossh -M 0 -t remote "tmux new-session -A -D -s $RANDOM$RANDOM$RANDOM$RANDOM"
with appropriate ServerAliveInterval and ServerAliveCountMax settings. It works somewhat nicely with dodgy ssh conncetions too. I'm aware of mosh, but this one even outlives when I put the laptop to sleep. Also mosh doesn't allow X forwarding, and I enable that for sharing the clipboard (yes, I'm aware of the security implications). And if I want to leave something long-running, I can just close the window and reattach later.
Re:How to move a running process into a tmux session (2020) by skhm on Wednesday October 05, 2022 @05:29AM (#33093149)
Mosh should survive a laptop sleep no problem - if it doesn't, something is misconfigured. X forwarding is a dealbreaker though.