- Setting/Unsetting values
- Saving session
- Auto complete
- File Explorer
- Repeating commands
- Bookmarks
- Searching Text
- Indentation
set number # set
set nonumber # unset
set number! # toggle
set numberwidth=3 # key=value
set number numberwidth=3 # Multiple setting at once
mksession my-work-session.vim
Press Ctrl+n
in insert mode.
Give ::Explore
command
- Press
qX
where X=any letter to start recording. - Use some commands
- Press
@X
where X=previously used letter.
You can use @@
after using @X
once.
- mX where X=a-z for setting local bookmarks(In same file).
- mX where X=A-Z for setting global bookmarks(In any file).
- 'X where X=a-zA-Z to go to the bookmarks.
- :marks to show all the bookmarks.
Type /
in normal mode, then insert keyword and press enter.
Cursor will go to the first occurrence of the keyword. Press
n
to go to the next occurrence or N
to go to previous
occurrence.
Pressing *
will search the current word under cursor.
=
is used to indent a line.
:tabm i
- Move current tab to i th position.:tabm +i
- Move current tab i place right.:tabm -i
- Move current tab i place left.
Resize:
Ctrl + w + <
- Decrease window widthCtrl + w + >
- Increase window widthCtrl + w + -
- Decrese window heightCtrl + w + +
- Increase window height
Move placement:
Ctrl + w + R
- Move window up/leftCtrl + w + r
- Move window down/right