GNU screen
Introduction
GNU Screen is a window manager for virtual terminals. The screen command is used to manage screen sessions. Starting screen by itself will run a new session with a shell in a new virtual terminal. screen can be followed with other commands like screen vim test.txt. This will start a new session with a new virtual terminal running the command you specified. screen -r will resume a detached session. Adding -d will also detatch any other connections to this session.
Key bindings
A key binding starts with the command key and is followed by second key. The command key is
CTRL-A by default. Here are several second key bindings:
- ? - displays a help screen.
- c - creates a new virtual terminal window.
- K, or k - destroys the current window.
- n or SPACE - changes to the next window.
- p - changes to the previous window.
- w - displays available virtual terminal window numbers and titles.
- A - changes the current window's title.
- d - detach from the
screen session.
- x - lock the
screen session with a password.
- : - execute a command.
Screen commands
The CTRL-A + : key binding will bring up a command prompt. Typing screen top will run top in new virtual terminal.
References
- CTRL-A + ? from within
screen.
-
man screen.