#----------------------------------------------------------------------------------
# VI edior shortcuts
#----------------------------------------------------------------------------------
Opening files:
#---------------
vi filename To open a file 'filename' with vi editor
vi + filename To open a file 'filename' with vi editor - In last line to append
Saving files:
#---------------
ESC :wqTo save and exit the current open file
ESC :wq!To save and exit the current open file - forcefully (for read only files)
Modes:
#---------------
a To append after cursor
A To append at the end of line
i To insert before cursor
I To insert in beginning of line
o To add new line below cursor
O To add new line above cursor
Misc options:
#---------------
ESC :se nuTo display line numbers in current open file
ESC :se nonuTo turn off displaying line numbers in current open file
Wednesday, August 27, 2008
Unix commands for DBAs - Part 2
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment