Linux commands (text editor)

  • and vi vim editor: insertion mode, normal mode, the line mode
  • A group of mode (i, a, o, I, A, O) bond ---> insert mode Insert mode (press Esc to exit) ----> J mode to enter a group
  • General mode (by: key) ---> Mode bottom line mode (by ESc) ---> enters the general mode
  • Bottom line mode, wq is written and saved w == write q == quit wq! If the case can not save exit may be used wq!.! Q is forced to exit! Force is not written to the
  • i, a, o, I, A, O basis Kai释
  • name Explanation
    i Is inserted before the cursor position
    O Insert the next line of the cursor position
    a Inserted after the cursor position
    I The first row is inserted at the cursor position
    A Line inserted position cursor position
    O Insertion position of the cursor on a line

  • In the line mode input: set nu Enter display line numbers are not input set nonu the transport line number
  • Enter capital letters G to the end of the file input lowercase gg general mode back to the first line
  • General mode Ctrl + F document is too long to display the next page Ctrl + B Previous show
  • In the line mode: 100 Enter cursor to row 100
  • Under normal mode using the / cpp cpp can find Enter
  • In general, the line where the cursor mode, the input yy, to copy the current contents of the cache line, n NYY replication begins with the line of the cursor, yy and p corresponds conjunction Paste
  • General mode the undo function is lowercase u (times can be revoked) Ctrl + r anti revocation
  • Lowercase characters dd normal mode cursor to delete the contents of the row n rows lowercase characters ndd delete the cursor line
  • Under the bottom line mode: 3,6d Enter deleted from the third row to the sixth row of content
  • 2 the entire character file replacement characters 1% s / 1 character / character 2 / g cursor line character S 2 the alternative character line mode 1/1 character / character 2 / g

Guess you like

Origin www.cnblogs.com/hph1728390/p/11082820.html