View Tutorial Metadata Edit Content Revision History Add to Watchlist Add New Tutorial Introduction to VIM

Introduction to VIM

VIM is an editor which, in time, can enable you to edit faster than you would with most other editors. However, you first have to get used to the numerous shortcut keys.

First of all, there are two main modes of operation:

  • Normal mode: allows you to navigate through the file. This is the default mode when starting vim. Interestingly, while you can use the arrows to navigate through open files, you are encouraged to use the 'h'/'j'/'k'/'l' keys to move left/down/up/right respectively. By using them, you have the benefit of not having to reach the keypad to press the arrow keys when your hands are already over the letters.
  • Insert mode: while in insert mode, everything you type will be inserted in the currently open file.

To switch from one mode to another, use:

  • 'i' to get from Normal mode to Insert mode
  • The Escape key to exit Insert mode and return to Normal mode.

There are other modes besides those two. Another important one is the command mode, where you are giving commands to the editor. To enter this mode, you can type in the ':' character while in Normal mode. The focus will go to the command line at the bottom of vim. A useful command you can try is

:help

This should guide you through the basics of VIM.

Only plain text supported.

Optional

Required - will be kept private

Optional

 
 

Rating: (0+, 0-) In: Vim