What command is used Linux with vim editor ?

The vi editor is a powerful text editor available in most Unix-like operating systems, including Linux. It’s often considered a standard tool for editing text files in the command line interface. Here’s a basic tutorial to get you started with vi:

What is Vim?

Vim is an acronym for vi improved. It is a free and open-source cross-platform text editor. It was first released by Bram Moolenaar in 1991 for UNIX variants.

Vim is based on the original Vi editor, which was created by Bill Joy in 1976. In the 90’s, it started becoming clear that Vi was lacking in some features when compared with the Emacs editor. So Bram implemented many missing features and released it under the name Vim.

Starting the vi Editor


The following table lists out the basic commands to use the vi editor −

Understanding Modes:

Vim has different modes for different tasks. The three main modes are:

  • Normal mode: For navigation and executing commands.
  • Insert mode: For inserting and editing text.
  • Visual mode: For selecting blocks of text.
Navigation:
Editing:
Saving and Exiting:
Visual Mode:

When editing text with Vim, visual mode can be extremely useful for identifying chunks of text to be manipulated.

Vim’s visual mode has three versions: character, line, and block. The keystrokes to enter each mode are:

Here are some ways to use each mode to simplify your work.
Practice:

Vim is all about muscle memory. Practice regularly to get comfortable with its commands and shortcuts.

Remember, learning Vim takes time and patience. Don’t get discouraged if you find it challenging at first. Start with basic commands, and gradually incorporate more advanced ones as you become more comfortable. Happy editing!

Leave a Comment