--On dimanche 31 mars 2002 23:31 -0800 Steve Brown <[EMAIL PROTECTED]> wrote:
> Well, if by unix timestamp you mean seconds past the epoch, just call > > date -r [timestamp] > > and the output will be a real date. You can adjust the format as necessary > using plain old date formatting I believe. YMMV depending upon your OS Or you can use this perl script (pipe your file into it): #!/bin/perl $opt_g=0; sub epoch2time { ($sec,$min,$hour,$mday,$mon,$year,$wday,$yday,$isdst) = $opt_g==0?localtime(@_[0]):gmtime(@_[0]) ; sprintf("[ %d = %02d/%02d/%04d %02d:%02d:%02d %s]", @_[0],$mday,1+$mon,1900 + $year,$hour,$min,$sec,$opt_g?"GMT":""); } while (<>) { $_ =~ s/\b(\d{9,10})\b/epoch2time($1)/ge ; print $_ ; } -- Jerome Fleury === Archive at http://www.open.com.au/archives/radiator/ Announcements on [EMAIL PROTECTED] To unsubscribe, email '[EMAIL PROTECTED]' with 'unsubscribe radiator' in the body of the message.