If I type history command, I can view only 1000 lines. I want to view more than that. It will be nice If I can view all commands typed between certain dates or months.
Is this possible? If so, how to do this?
If I type history command, I can view only 1000 lines. I want to view more than that. It will be nice If I can view all commands typed between certain dates or months.
Is this possible? If so, how to do this?
add some commands to .bash_logout to organize your history files
e.g.
However, one problem: .bash_logout doesn't seem to run in a lot of X-based environments. On a ssh account, such as with a virtual server, it works fine.
You want to set the bash variables
HISTSIZE
andHISTFILESIZE
in your.bashrc
.HISTSIZE
determines how many comands are retained in history.HISTFILESIZE
determines how many lines of history are stored in the file in which they are persisted, usually.bash_history
.