Sample Header Ad - 728x90

What is the closest xterm-like $TERM setting that does not have an alternate screen?

1 vote
1 answer
372 views
Some terminal applications (e.g. mosh) use the terminal in the alternate screen, thereby disabling the terminal emulator's local scrolling. mosh does not allow overriding its terminal settings (as far as I could find), so one simple way to force it to not use the alternate screen and (thus) keep local scrolling working is to tell it the terminal doesn't have an alternate screen: env TERM=dumb mosh mosh now no longer breaks scrolling, unfortunately TERM=dumb also doesn't have any other modern-ish terminal features, such as setting the application name in the titlebar. More useful is TERM=linux, but that still doesn't set the app name in the titlebar. **So, what is the most xterm-like $TERM setting that does not support an alternate screen?** notes:\ ‑ My default TERM value is xterm-256color.\ ‑ I realise there are other workarounds, like using tmux inside mosh, but sometimes I don't want to do that.\ ‑ I realize this only gives me the local scroll buffer, so this still misses output if the mosh session was disconnected and then reconnected itself. But sometimes that is good enough.
Asked by JanKanis (1421 rep)
Feb 19, 2022, 10:49 PM
Last activity: Feb 20, 2022, 09:39 AM