Chapter 2 Using the vi Text Editor Flashcards

1
Q

Append text at the end of the current line

A

A

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

Change current word

A

cw

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

Changes current line

A

cc

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

Changes from the current cursor position to the end of the line

A

C

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

Continue the search in the opposite direction

A

N

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

Continue the search in the same direction

A

n

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

Copies the current line and the next two lines into the buffer

A

3yy

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

Foward search

A

/<string></string>

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

enter command line mode

A

:

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

Insert text left of the cursor

A

i

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

Move cursor to the beginning of the line

A

^ carot symbol

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

move cursor left to the previous word

A

b

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

move cursor to first line of the document

A

gg

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

move cursor to specific line

A

<line>G
</line>

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

Move the cursor right to the next word

A

w

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

Open a new line above the current line and start inserting text

A

O

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
17
Q

Open a newline below the current line and start inserting text

18
Q

Pastes the lines from the buffer in the line above the cursor

19
Q

Quit vi if file has not been modified

20
Q

Quit vi if the file has been modified but any modifications will be lost

21
Q

move down half a page

22
Q

write current file to disk and quit

23
Q

Yank(copies) current line into the buffer

24
Q

append text to the right of the cursor

25
delete a character in current cursor position
x
26
delete character to left of the cursor
X
27
deletes a word from the current cursor position to the end of the word
dw
28
deletes the current line
dd
29
deletes the current line and next four lines and places them into the buffer
5dd
30
deletes the current line and puts it into the buffer
dd
31
insert text at the beginning of the current line
I
32
move cursor to the last line of document
G
33
move the cursor to the last character on the line
$
34
move cursor up half a page
crtrl + u
35
move cursor back a full page
ctrl + b
36
move cursor forward a full page
ctrl + f
37
pastes the lines from the buffer in the line below the cursor
p
38
repeat last command
.
39
replaces the character in the current position
r
40
reverse search
?
41
undo last edit
u