Using VIM (originally VI) Visual Improved Text Editor
VIM or VI is the de facto text editor for all Unix systems.
This post is for those who want to learn how to use VI. I am not going to get into VI vs Emacs or any other religious wars such as Linux vs Windows etc. The simple fact is that any Unix box you use will have VI installed so knowing at least the basics will help you in a pinch (or when your system is floundering you can rescue it.)
Start Here
- Slide Deck Introduction to VIM
- Try out VIM Tutor
- More VIM practice
Essential Commands (short quick ref for VIM)
ESC - change to command mode. The following commands will then work::q! - quit without saving
:wq - write changes then quit
i - insert mode (enter text)
dd - delete one line
yy - copy current line
p - paste last copied /deleted line
R - replace until ESC is hit
r - replace one character
/text - locate the string text search forward in the file (then n for next)
Other VIM Resources
- VIM official website
- Game for learning VIM
- VIM Tutor
- Basics of VIM: VIM TL;DR
- A few more commands VIM Quick Ref
No comments:
Post a Comment