linux history command with timestamps

Config output format in HISTTIMEFORMAT with below command: echo ‘export HISTTIMEFORMAT="%d-%m-%y %T" ' » ~/.bash_profile; bash then history to see the different To make the changes permanent follow the below steps, <code><span class="pln">vi </span><span class="pun">~/.</span><span class="pln">bashrc</span></code> you need to add the below line to .bashrc file and then save it, <code><span class="pln">export HISTTIMEFORMAT</span><span class="pun">=</span><span class="str">"%d/%m/%y %T "</span></code> run the below command to source .bashrc file, <code><span class="pln">source </span><span class="pun">~/....

April 16, 2015 · 1 min · longka