Skip to content

Commit feb1226

Browse files
committed
Add instructions for how to use screen
1 parent 5209e44 commit feb1226

2 files changed

Lines changed: 114 additions & 0 deletions

File tree

.vscode/settings.json

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88
"alefragnani",
99
"Aliquam",
1010
"aliquet",
11+
"alwayslastline",
1112
"amet",
1213
"anbox",
1314
"angll",
@@ -49,6 +50,7 @@
4950
"damirarh",
5051
"dapibus",
5152
"Deepti",
53+
"defscrollback",
5254
"Dependi",
5355
"devmode",
5456
"Dhhmm",
@@ -95,6 +97,7 @@
9597
"groupname",
9698
"Gruntfuggly",
9799
"gstatic",
100+
"hardstatus",
98101
"hashnode",
99102
"headhr",
100103
"hendrerit",
@@ -236,6 +239,8 @@
236239
"Sandfort",
237240
"sapien",
238241
"scelerisque",
242+
"screenrc",
243+
"scrollback",
239244
"semántico",
240245
"semântico",
241246
"sémantique",

content/debian/screen.md

Lines changed: 109 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,109 @@
1+
+++
2+
title = "Screen Application"
3+
date = 2025-05-06
4+
extra = { series = "Debian" }
5+
taxonomies = { tags = ["Debian"] }
6+
+++
7+
8+
Source: <https://linuxize.com/post/how-to-use-linux-screen/>
9+
10+
# Check if Installed
11+
12+
```sh
13+
screen --version
14+
```
15+
16+
# Installation command
17+
18+
```sh
19+
sudo apt install screen
20+
```
21+
22+
# Start session
23+
24+
## Unnamed
25+
26+
```sh
27+
screen
28+
```
29+
30+
## Named
31+
32+
Where `session_name` is the name of the session
33+
34+
```sh
35+
screen -S session_name
36+
```
37+
38+
# List sessions
39+
40+
```sh
41+
screen -ls
42+
```
43+
44+
# Reconnect to session
45+
46+
```sh
47+
screen -r
48+
```
49+
50+
# In session commands
51+
52+
- NB: Typing `exit` closes the screen.
53+
- Both in the help and below all commands are **preceded by pressing** <kbd>Ctrl</kbd>+<kbd>a</kbd> then releasing both buttons.
54+
Eg. To disconnect You press <kbd>Ctrl</kbd>+<kbd>a</kbd> simultaneously then release both buttons then press <kbd>d</kbd> alone.
55+
- In some versions the help commands are shown as either `^A` or `^A: a`. If it shows `^A` then you press <kbd>Ctrl</kbd>+<kbd>a</kbd>, however if it shows `^A a` you press only <kbd>a</kbd>.
56+
57+
## Detaching
58+
59+
<kbd> d </kbd>
60+
61+
## Help
62+
63+
<kbd> ? </kbd>
64+
65+
## Window List
66+
67+
Used to select open screens or know if your in a screen
68+
69+
<kbd> “ </kbd>
70+
71+
## Start up a new screen
72+
73+
<kbd> c </kbd>
74+
75+
## Rename current screen
76+
77+
<kbd> A </kbd>
78+
79+
## Kill current screen
80+
81+
<kbd> \ </kbd>
82+
83+
# Screen Config
84+
85+
First create or open screen config file
86+
87+
```sh
88+
nano ~/.screenrc
89+
```
90+
91+
Sample Config Contents
92+
93+
```
94+
# Turn off the welcome message
95+
startup_message off
96+
97+
98+
# Disable visual bell
99+
#vbell off
100+
101+
102+
# Set scrollback buffer to 10000
103+
defscrollback 10000
104+
105+
106+
# Customize the status line
107+
hardstatus alwayslastline
108+
hardstatus string '%{= kG}[ %{G}%H %{g}][%= %{= kw}%?%-Lw%?%{r}(%{W}%n*%f%t%?(%u)%?%{r})%{w}%?%+Lw%?%?%= %{g}][%{B} %m-%d %{W}%c %{g}]'
109+
```

0 commit comments

Comments
 (0)