history

History events

The basic structure of shell history starts with a list of events. An event is anything you’ve entered into the shell, followed by the Return or Enter key. Each event is assigned an index number (a line number), and you can view and recall events by using event designators.

1
2
3
4
5
HISTTIMEFORMAT='%F %T '
HISTCONTROL=$HISTCONTROL:ignorespace:ignoredups
HISTSIZE=100
HISTFILESIZE=100
HISTIGNORE='ls'

reference

Stupid Bash tricks