Unix vi editor i - Insert at cursor (goes into insert mode) ESC - Terminate insert mode u - Undo last change C - Delete contents of a line after the cursor and insert new text. Press ESC key to end insertion. D - Delete contents of line after the cursor dd - Delete line 3dd - Delete 3 lines. dw - Delete word ~ - Change case of individual character :1,$d - delete all content of file :w - Save the file but keep it open :q - Quit without saving :wq - Save the file and quit Back to Index