Comment Comment by olifante How about SSH straight into screen?Here's how to define a shell function for quickly attaching to an existing screen session after connecting via ssh (or creating a new one if none exists): sshcreen () { ssh -t "$@" screen -xRR } Works with bash and zsh. Usage is pretty simple: $ sshcreen [email protected] You can use normal ssh arguments, such as the port: $ sshcreen root@localhost -p 2222 Detach the session with CTRL-A + D, reattach by re-running the sshcreen command you previously used.PS: repurposed my comment from a recent discussion: https://news.ycombinator.com/item?id=32486892 parent olifante 4 years ago
Here's how to define a shell function for quickly attaching to an existing screen session after connecting via ssh (or creating a new one if none exists):
Works with bash and zsh. Usage is pretty simple: You can use normal ssh arguments, such as the port: Detach the session with CTRL-A + D, reattach by re-running the sshcreen command you previously used.PS: repurposed my comment from a recent discussion: https://news.ycombinator.com/item?id=32486892