Subject: [ILUG] tip of the day..epoch to date
From: "John P. Looney" <[email-masked]>
To: ilug <[email-masked]>
Date: 25 Aug 2003 11:38:20 +0100

When dealing with wierd tools like qmail, most of the dates in logs are
in epochtime (seconds from 1970).

 So, to change the format easily, you can run;

function epoch ()
{
    date -d "1970-01-01 $1 sec" +"%Y-%m-%d %T %z"
}

 Then, you can run

midir [0]  epoch 1030981290
2002-09-02 15:41:30 +0100

 yay. No need to resort to a perl one liner.

John