Linux commands to learn -history command

Linux, the command is to show the role of history and the history of executed commands.

  1. View history of all command execution record
    history
  2. View recent 13 history execute the command
    history 13
  3. Execution history, the serial number for the command 123
    ! 123
  4. Repeat the command
    !!
  5. Check the cat command execution history
    history | grep cat
  6. Clear all historical records command
    history -c

Guess you like

Origin www.cnblogs.com/wintest/p/11183718.html