Vim For Editing Files In Linux
Description
Info
Level: Beginner
Presenter: Eli the Computer Guy
Date Created: September 14, 2010
Length of Class: 35 Minutes
Tracks
Linux
Prerequisites
Introduction to Linux
Installing Linux
Basic Linux Tasks
Purpose of Class
This class teaches students how to edit configuration files in Linux using the text editor VIM.
Topics Covered
Starting VIM
Editing Files
Searching in Files
Opening, Saving and Exiting Files
Class Notes
Introduction
No .txt -- no file association
Starting VIM
Sudo vim XXX (opens a file, or creates file)
Sudo -- sometimes you need, sometimes not... if you use it it will always work...
To change ownership of a file (Sometimes needed to edit .ini and configuration files)- Sudo chown user file
Editing and Navigating
a = insert, esc = exit insert
:/ = find (use wildcards)
:/? = Find backward
n = next
Exiting and Saving
:q = quit
:q! = quit no save
:wq = save and quit
:e = open file
:w = save as
Final Thoughts...
Very complicated... Lots of options... these are good enough to start with....
Resources
Vim Website: http://www.vim.org/
Vim Manual: http://vimdoc.sourceforge.net/vimum.html