DEV Community

chair
chair

Posted on • Edited on

3

Screen commands

Screen is useful for running long scripts on linux virtual machines where you don't want to risk termination due to a disconnection.

The following commands are all you will ever need, probably. Most of the time.

download: sudo yum install screen
list sessions: screen -ls
start session: screen
detach from session: ctrl a + d
re-attach: if there is only one session running you can do screen -r else do screen -ls and get the desired session id and do screen -r <SESSION_ID>
kill session from inside the session: ctrl a + k + y
enable vertical scrolling: ctrl a + ESC

A lovely cheatsheet I forked from someone wiser than I, who also forked it from someone before them:
https://gist.github.com/aarobender/a503231e83b862c3757ab6527bdfc812

Top comments (0)

Billboard image

Create up to 10 Postgres Databases on Neon's free plan.

If you're starting a new project, Neon has got your databases covered. No credit cards. No trials. No getting in your way.

Try Neon for Free →

👋 Kindness is contagious

Please leave a ❤️ or a friendly comment on this post if you found it helpful!

Okay