|PICO Editor|vi Editor|


PICO Editor

Pico is a full screen editor. It is a very easy to use editor in a Unix environment.

To invoke the editor, just type in pico filename1.

You can use the arrow keys to move the cursor but you can also use the Ctrl key to move the cursor.

CommandDescription
Ctrl + eto the end of the current line
Ctrl + nto the next line
Ctrl + fforward the character
Ctrl + ato the beginning of the current line
Ctrl + pto the previous line
Ctrl + bbackward one character

Marking Areas for deleting a large block of text

  1. Press Ctrl + ^ to mark the beginning of the text to be deleted.
  2. Move the cursor to the end of the text to be deleted and press Ctrl + k. (Pressing Ctrl + u will restore the deleted text)

Marking Areas for copying a large block of text

  1. Press Ctrl + ^ to mark the beginning of the text to be deleted.
  2. Move the cursor to the end of the text to be deleted and press Ctrl + k.
  3. Press Ctrl + u at the position you want the text to be copied.

vi Editor

vi is a very powerful editor.

To invoke the editor, just type in vi filename1.

CommandDescription
^@ repeat last command
@buffer execute command stored in buffer
a append text after cusor
A append text at end of line
^A unused
b back up to beginning of word
CTRL-b page back
B back up to beginning of work, ignoring punctuation
^B scroll back one window's worth
c change text
cw change word
c$ change remainder of line
C change to end of line
d delete text
dw delete word
d$ delete remainder of line
dd delete entire line
D delete to end of line
^D (command mode) scroll down half-window (insert mode) back up one tab stop
e move to end of word
E move to end of word, ignoring punctuation
^E scroll down one line
f find next character forward on current line
CTRL-f page forward
F find previous character backward on current line
^F scroll forward one window
g unused
G go to specific line or end of file
1G first line
CTRL-G show current file, line, and status
h cursor left
H go to top line of screen
^H (command mode) cursor left (inser mode) backspace
i insert text before cursor
I insert text at beginning of line
^I (insert mode) tab
j cursor down
J join lines
^J cursor down
k cursor up
K unused
l cursor right
L go to bottom line of screen
^L redraw screen
m mark current position in register
M go to middle line of screen
^M carriage return
n repeat last search command
N repeat last search command in opposite direction
^N cursor down
o open line below current line
O open line above current line
p put yanked or deleted text after or below cursor
P put yanked or deleted text before or above cursor
^P cursor up
q unused
Q switch to ex
^Q (insert mode)escape next character
r replace character
R replace characters
^R redraw screen
s change current character and leave in input mode
S change entire line
t move cursor forward to character before next character typed
T move cursor backward to character after next character typed
^T (insert mode) tab
u undo
U undo line
^U scroll screen up half window
v unused
V unused
^V (insert mode) escape next character
w move to beginning of next word
W move to beginning of next word, ignoring punctuation
^W (insert mode) back up to beginning of word
x delete character under cursor
xp exchange characters
X delete character before cursor
y yank (copy) text
yy yank line to internal buffer
(nn)yy yank (nn) lines to buffer
Y yank entire line
^Y scroll up one line
z redraw screen positioning cursor when followed by CR at the top, . at middle, and - at the bottom of the screen
ZZ save and exit
:q quit
:w write (save)
:q! quit (abort changes)
:wq write and quit
/(string) search forward
?(string) search backward
0 go to first position of current line
$ go to last position of current line


© 1996-2002: Hann So
email: sohann@fhda.edu