Cheatography
https://cheatography.com
screen commands survival guide. Sorted by usefulness.
Enter / Quit
screen -S foo |
create a screen named "foo" |
screen -x foo |
attach to an existing screen named "foo" |
[^A] [d] or [^A] [^D] |
detach current screen |
exit or [^D] (in screen shell) |
exit the shell starting the screen thus exit the screen |
exit or [^D] are not screen commands but bash ones
Syntax convention
^ |
[Control] key |
[^A] |
[Control] + [a] |
[a] |
[a] |
[A] |
[Shift] + [a] |
[^A][A] |
[Control] + [a] then [Shift] + [a] |
[^A][A] |
different from [^A][a] |
|
|
Window (screen tabs)
[^A] [c] |
Create a new window |
exit or [^D] (in screen shell) |
exit the current shell created by the window, thus exit the window |
[^A] [0] |
Go to window 0 |
[^A] [3] |
Go to window 3 |
[^A] [n] |
Go to next window |
[^A] [p] |
Go to previous window |
exit or [^D] are not screen commands but bash ones
Disclaimer
This cheat only describe the default key bindings |
key bindings can be modified by editing ~/.screenrc or another screenrc file |
|
|
Split screen
[^A] [S] |
Split screen horizontally |
[^A] [|] |
Split screen vertically |
[^A] [^I] or [^A] [Tab] |
Change splitted part |
[^A] [Q] |
Remove all splitted parts |
Misc
[^A] [A] |
Rename current window |
[^A] [k] |
Kill current window |
[^A] [^A] |
Switch to last used window |
[^A] [a] |
Send [^A] to current screen |
|
Created By
Metadata
Favourited By
and 10 more ...
Comments
Ian 13:32 30 Dec 11
This cheatsheet should mention that [^A] is actually just the escape key, which by default is ^A but can be something else. For example, Ubuntu's screen wrapper byobu also uses F12 depending on your keybindings.
RicoPags, 21:12 4 Jan 12
For me, ^a,s and ^a,q are the equivalent of bash ^s and ^q [freeze/unfreeze terminal]
RicoPags, 21:13 4 Jan 12
I see holding shift makes a difference and does split screens. That's great information, perhaps it would be best to add the lowercase so nobody is confused?
gissehel, 21:42 4 Jan 12
@Ian : In fact ^A (in screen dialect) is not [Esc] but it's what emacs calls [C-a] or what windows calls [Ctrl+a]. which is obtained by pressing [Ctrl] then pressing [A] then releasing [A] then releasing [Ctrl]. It's true that it should be documented (even it's a classical unix representation of shotcuts, you can find it for example in pine or mutt interface).
gissehel, 21:46 4 Jan 12
@RicoPags : What should also be documented : While [^A] mean [Ctrl+a] in screen help, [^A] [A] doesn't mean [Ctrl+a] [a] but [Ctrl+a] [Shift+a]. It's screen own convention (the one you'll see in [^A] [?]) but it's very misleading.
Kakolukia, 08:40 7 Feb 14
Would you mind adding the Enter/Quit commands from https://library.linode.com/linux-tools/utilities/screen#sph_managing-screen-attachment ?
SencerH, 09:28 26 Jun 18
There should be scroll buffer shortcut. Would you please add ^A + Esc combination and how to use this mode?
Add a Comment
Related Cheat Sheets