IT Logs 落個史
2017-06-05
Linux bash history add timestamp
1.
vim ~/.bashrc
在最下方加入
HISTTIMEFORMAT='%F %T '
-
%F – expands to full date same, as %Y-%m-%d (year-month-date).
-
%T – expands to time; same as %H:%M:%S (hour:minute:seconds).
2.
source ~/.bashrc
Newer Posts
Older Posts
Home
Subscribe to:
Posts (Atom)