motions Flashcards

1
Q

h j k l

A

left, up, down, right

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

w, b

W, B

A

next word, previous word

Use whitespace as the word boundary

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

e, ge

E, gE

A
end of (next) word, end of previous word
Use whitespace as the word boundary.
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

0 (zero)

A

To first character in line

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

^ (caret)

A

To first non-blank character in line

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

$

A

To last character in line

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

N | (s a pipe)

A

To column N

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

N f{char}

A

To the Nth occurrence of {char} forward in file

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

N F{char}

A

To the Nth occurrence of {char} backward in file

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

N G

A

goto line N. Default is last line.

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

gg

A

goto first line

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

/(string)

A

Search for a match forwards - string is regex

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

?(string)

A

Search for a match backwards - string is regex

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

n

A

repeat last search

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

N

A

repeat last search in opposite direction

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q
  • (star character)
A

search forward for the identifier under the cursor

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

(octothorpe)

A

search backward for the identifier under the cursor

18
Q

g* or g#

A

like * or # but also finds partial matches

19
Q

gd

A

goto local declaration of identifier

20
Q

gD

A

goto global declaration of identifier

21
Q

:ju[mps]

A

print the jumps list

22
Q

:mark

A

print the active mark list

23
Q

m{a-zA-Z}

A

mark the current position with {mark}

24
Q

`{a-z}

A

goto mark in current file

25
Q

`{A-Z}

A

goto mark in any file

26
Q

`. (backtick + period)

A

goto position of last change in file

27
Q

`` (two backticks)

A

goto position before last jump

28
Q

% (solo percent sign)

A

find the next brace, bracket, or paren in this line and goto it’s match.

29
Q

N H

A

move cursor to Nth line in window.

Default: move to first line.

30
Q

M

A

move cursor to middle line in window

31
Q

N L

A

move cursor to Nth line in window from the last line.

Default: move to last line.

32
Q

CTRL-E

A

scroll window 1 line down

33
Q

CTRL-Y

A

scroll window 1 line up

34
Q

CTRL-F

A

scroll window forwards (down) one screen

35
Q

CTRL-B

A

scroll window backwards (up) one screen

36
Q

CTRL-D

A

scroll down a half window

37
Q

CTRL-U

A

scroll up a half window

38
Q

zt

A

redraw, current line at top

39
Q

zz

A

redraw centering current line

40
Q

zb

A

redraw, current line at bottom