-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathcommands.html
More file actions
60 lines (60 loc) · 4.06 KB
/
commands.html
File metadata and controls
60 lines (60 loc) · 4.06 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>ed(itor) manual: Commands</title>
<link rel="apple-touch-icon" sizes="180x180" href="assets/favicon/apple-touch-icon.png">
<link rel="icon" type="image/png" sizes="32x32" href="assets/favicon/favicon-32x32.png">
<link rel="icon" type="image/png" sizes="16x16" href="assets/favicon/favicon-16x16.png">
<link rel="manifest" href="assets/favicon/site.webmanifest">
<link rel="stylesheet" href="base.css">
</head>
<body>
<div id="title">
<h2>ed(itor) manual</h2>
<br>
<h3>Commands</h3>
</div>
Note: [] is optional arguments.
<br>
[f,l]p (print): Prints the contents of the first to the last line.<br>
If f or is not specified, the current line is used. If l is not specified, the l argument will be equals to f<br>
Changes the current line to the last printed line<br><br>
[f,l]n (print with number): Prints the line number and the contents of the first to the last line.<br>
If f or is not specified, the current line is used. If l is not specified, the l argument will be equals to f<br>
Changes the current line to the last printed line<br><br>
[f,l]l (list): Prints the contents of the first to the last line followed by a '$' symbol.<br>
If f or is not specified, the current line is used. If l is not specified, the l argument will be equals to f<br>
Changes the current line to the last listed line<br><br>
h (show error): Shows a detailed version of the error.<br><br>
H (show error and don't surpress any errors): In every error that will occur, don't try to send a error emoji, also prints the last error.<br><br>
q (quit): Quits from $ed.<br><br>
Q (forced quit): Quits from $ed without any buffer warning.<br><br>
w (write): Sends all the contents of the internal $ed buffer.<br><br>
wq (write & quit): Sends all the contents of the internal $ed buffer and quit.<br><br>
[f,l]g/re/command (search): Run the specified command if any line from first to the last parameter matches the regular expression (re).<br>
If f is not specified, will use the first line as beggining. If l is not specified, the last line is used.<br>
Changes the current line to the last match<br><br>
[f,l]r/re/new (replace): Replaces the lines from first to the last lines if the regular expression (re) matches.<br>
If f is not specified, will use the first line as beggining. If l is not specified, the last line is used.<br>
Changes the current line to the last match<br><br>
[B]+n (advance lines): Advances B+n lines. If N is not specified, will use the current line.<br>
Changes the current line<br><br>
[B]-n (return lines): Return B-n lines. If N is not specified, will use the current line.<br>
Changes the current line<br><br>
[n]a (append): Appends one or more lines starting at line n. If N is not specified, will use the current line.<br>
If a single 'dot' is sent to the command. The command stops. Note: line (n as) zero is supported.<br>
Changes the current line to the last affected line.<br><br>
[n]i (insert): Inserts one or more lines starting at line n. If N is not specified, will use the current line.<br>
If a single 'dot' is sent to the command. The command stops<br>
Changes the current line to the last affected line.<br><br>
[f,l]c (change): Changes one or more lines starting at line f and stops at line l. After that the command will become a append/insert command<br>
If f or is not specified, the current line is used. If l is not specified, the l argument will be equals to f<br>
If a single 'dot' is sent to the command. The command stops<br>
Changes the current line to the last affected line.<br><br>
[f,l]d (delete): Deletes one or more lines starting at line f and stops at line l.<br>
If f or is not specified, the current line is used. If l is not specified, the l argument will be equals to f<br><br>
n (any number): Changes the current line to n.<br><br>
</body>
</html>