This is my little cheatsheet for screen - one of my most used cli programs under Linux. I know that some people hyping alternatives like tmux like mad, but I prefer working under the "if it ain't broken, don't try to fix it" premise.
I have also added my little ~/.screenrc which I prefer to use on the machine I work with.
Cheatsheet:
Key | Action |
---|---|
Ctrl+a c | create new window |
Ctrl+a n | next window |
Ctrl+a p | previous window |
Ctrl+a " | select a window from a list |
Ctrl+a Ctrl+a | jump to the previous viewed window |
Ctrl+a A | set the title of the current window |
Ctrl+a S | split horizontally |
Ctrl+a | |
Ctrl+a :resize | resize the active region |
Ctrl+a F | fit screen size to terminal size |
Ctrl+a X | remove active region |
Ctrl+a [Tab] | switch between regions |
Ctrl+a d | detach from screen |
Ctrl+a [ | enter scrollback mode |
Ctrl+a ] | exit scrollback mode |
Ctrl+a ? | show key bindings and command names |
~/.screenrc:
# F11 & F12 to go to next/previous window
bindkey -k F1 prev
bindkey -k F2 next
# disable startup text
startup_message off
# show a list of open windows in a screen session:
hardstatus alwayslastline
hardstatus string "%-w%{= BW}%50>%n %t%{-}%+w%<"
# important for editors like nano
altscreen on
Comments: