
Timestamps + History
Accurate timestamps are crucial for investigations. In this post we'll extend the bash shell to display the date/time during command execution and how to include the timestamp in the history file.
Interactive shell
# file ~/.bashrc
... # right at the end
export PS1='\[\e[1;0m\]\D{%m/%d/%Y %H:%M:%S} \[\e[1;36m\]\u@\h \[\e[33m\]\w\[\e[0m\]\n \$ » '
History command

Notes
Key Points to Keep in Mind About the Bash Shell Environment, History Command, and Timestamps
References
Last updated

