LKBEN11094: A command line window manager: screen


This article has not been checked!

LKB | Created: 02/04/2020 | Version: 0 | Language: EN | Rating: 0 | Outdated: False | Marked for deletion: False

Author: Wim Peeters - Keskon GmbH & Co. KG


Symptom

Screen is a full-screen command line window manager that multiplexes a terminal session between processes

Cause

none

Solution


To use screen you need to know the ctrl-a command wich means type control key plus a. This is the basic keystroke to know. When this keystroke has been entered, the program waits for a command to be given.

You just start screen by typing "screen" in your shell. (e.g. bash) You can have your settings saved in .screenrc.

 The following table shows a few (not all of them) of the interesting key bindings which I use the most:

command Function Explication
C-a 0 select 0 Selects screen 0
C-a 1 select 1 Selects screen 1
C-a n select n Selects screen n
C-a 9 select 9 Selects screen 9
C-a A title Allow the user to enter a name
    for the current window.
C-a c screen Create a new window with a shell
    and switch to that window.
C-a C clear Clear the screen.
C-a d    
C-a C-d detach Detach screen from this terminal.
C-a D D pow detach Detach and logout.
C-a space    
C-a n    
C-a C-n next Switch to the next window.
C-a N number Show the number (and title)
    of the current window.
C-a backspace    
C-a h prev  
C-a p    
C-a C-p   Switch to the previous window
    (opposite of C-a n).
C-a ? help Show key bindings.
C-a C- quit Kill all windows and terminate screen.
C-a : colon Enter command line mode.
C-a [    
C-a C-[    
C-a esc copy Enter copy/scrollback mode.
C-a ] paste Write the contents of the paste buffer to the
    stdin queue of the current window.
C-a R attach Re-attach to a running session and if none
    exists create one
C-a R attach Re-attach to a running session and if none
    tell me without creating a session.
C-a x multi user Attach to a running session for
    for looking at it in multi screen mode.
    You can use it for attaching to!

 

 

You can find an ebook for screen on this website by clicking on the homepage and then on ebooks. You will find a link to the ebook. (or type "http://www.lubby.org/stable/ebooks/Screen/index.html" in your browser)

About the Author

Wim Peeters is electronics engineer with an additional master in IT and over 30 years of experience including time spent in support, development, consulting, training and database administration. Wim has worked with SQL Server since version 6.5. He has developed in C/C++, Java and C# on Windows and Linux in different European countries and different European languages. He writes knowledge base articles to solve IT problems and publishes them on the Lubby Knowledge Platform where he is one of the most important contributors and the main developer.

Disclaimer:

The information provided in this document is intended for your information only. Lubby makes no claims to the validity of this information. Use of this information is at own risk!