You may not see this two weeks later comment, but in case you do have reply notifications or check the threads page:
Thanks for the timestamp function! I can't believe it never occurred to me to do something like that before, and unlike you I think I actually will be using it now and then :)
If you like the timestamp function, this is available as a tool in the `moreutils` package as `ts`. You can simply pipe the output of any command to ts and have a timestamp prepended to each line it outputs. Extremely useful for streaming logs