Getting Started With Vim
You do not need to be a command line wizard to be able to use Vim. Using Vim consists in three simple steps: opening Vim, making the necessary text edits, then saving and exiting.
- Opening Vim
vim helloworld.txt
Using the vim
command followed by a file name will result in opening that file in the vim editor. If that file does not already exist in your current directory, it will be created.
In this case, we see [New File], because I did not have a helloworld.txt already present in my directory, so I am creating it.
2. Using Vim
In order to go any further, we need to get a grasp on how Vim generally works. These are the key concepts you need to remember:
- Vim is a text editor (just like VSCode) that runs in your terminal.
- Once you open Vim, you get into an interactive mode.
- IMPORTANT: Vim has multiple modes.
- IMPORTANT: Vim operates on commands.
- Vim is extremely configurable.
Theory behind modes & commands: