On Monday, 23 November 2020 21:47:11 GMT Jack wrote: > For many years, I've had this small script in my home directory - > unfortunately I rarely remember to use it. I have no idea where I got > it, but it's got a timestamp of about four years ago. However, now > that I actually look at it, the author is a frequent contributor to > this list, so it was likely mentioned here. > > #!/usr/bin/awk -f > ###################################################### ################### > # log-emerge: > # > # A filter which converts the time stamp on emerge log files to a human > # readable form. > # > # Written by Alan Mackenzie <[email protected]>, 2015-10-20. > # This script is in the public domain. > # > # To use, pipe all or part of a log file through this filter. > ###################################################### ################### > { > sec = strtonum(substr($1, 1, 11)) > $1 = strftime("%Y-%m-%d %H:%M:%S %z", sec, 0) ":" > print > }
There should be a one-liner in awk too. Someone will come along in a minute and tell us. At least, I hope so because I'd like to use it too. -- Regards, Peter.

