1.

What Is The Difference Between Command Mode & Insert Mode?

Answer»

Often sited as one of the main problems with vi, and equally often sited as being one of its BEST strengths, vi differentiates between a "Command mode" and an "INSERT mode." Understanding this difference is VITAL to learning vi. When one starts vi it starts in command mode. In this mode, one can move around the file, and issue commands to change certain areas of the text, cut, copy and paste sections of the text and do much more. Insert mode is where one can actually insert text. In other words, command mode is used to move around the document, and insert mode is used to type text into the document.

Commands such as: a, i, c, C, O, o and others will switch one from command mode to insert mode.

<Esc> or ^C will TAKE one out of insert mode and RETURN one to command mode.

Get used to this distinction. It is one of the things that makes vi different from most other editors. It also allows one to do a lot of things without taking one's hands from the standard keyboard position.

Often sited as one of the main problems with vi, and equally often sited as being one of its best strengths, vi differentiates between a "Command mode" and an "Insert mode." Understanding this difference is VITAL to learning vi. When one starts vi it starts in command mode. In this mode, one can move around the file, and issue commands to change certain areas of the text, cut, copy and paste sections of the text and do much more. Insert mode is where one can actually insert text. In other words, command mode is used to move around the document, and insert mode is used to type text into the document.

Commands such as: a, i, c, C, O, o and others will switch one from command mode to insert mode.

<Esc> or ^C will take one out of insert mode and return one to command mode.

Get used to this distinction. It is one of the things that makes vi different from most other editors. It also allows one to do a lot of things without taking one's hands from the standard keyboard position.



Discussion

No Comment Found