ClearFoundation Tracker - ClearOS
View Issue Details
0018191ClearOSsystem-base - Base Systempublic2017-12-10 10:242020-09-14 06:00
bchambers 
 
normalfeaturehave not tried
closedsuspended 
7.4.0 
 
0018191: Add timestamp to bash history
It would be nice for support/troubleshooting to have a timestamp of one command line changes were made.


Consider adding:

HISTTIMEFORMAT="%b %d %Y %T "

to /etc/profile.d/clearos.sh

so that 'history' command returns something like:

 998 Dec 10 2017 12:23:39 history
  999 Dec 10 2017 12:23:50 vi /etc/profile.d/clearos.sh
 1000 Dec 10 2017 12:23:55 history
No tags attached.
Issue History
2017-12-10 10:24bchambersNew Issue
2017-12-10 12:05NickHNote Added: 0006821
2017-12-12 08:49bchambersNote Added: 0006841
2018-02-21 09:26user2Statusnew => acknowledged
2018-03-30 11:36user2Categoryclearos-base - Base System => system-base - Base System
2020-09-14 06:00NickHNote Added: 0014671
2020-09-14 06:00NickHStatusacknowledged => closed
2020-09-14 06:00NickHResolutionopen => suspended

Notes
(0006821)
NickH   
2017-12-10 12:05   
Double-edged sword. It then stops you directly copying and pasting multiple lines from history to the command line in one go.
(0006841)
bchambers   
2017-12-12 08:49   
history | awk '{ print $6 }'
(0014671)
NickH   
2020-09-14 06:00   
Migrated to https://gitlab.com/clearos/clearfoundation/system-base/-/issues/6 [^]