Re: HowTo convert "seconds since `00:00:00 1970-01-01 UTC" into a human readable date
From: gmt (gmt_at_gotmail.com)
Date: 04/15/04
- Previous message: Sundaram Ramasamy: "Re: How to become a System Administrator?"
- In reply to: Hermann Peifer: "HowTo convert "seconds since `00:00:00 1970-01-01 UTC" into a human readable date"
- Next in thread: Bill Marcum: "Re: HowTo convert "seconds since `00:00:00 1970-01-01 UTC" into a human readable date"
- Reply: Bill Marcum: "Re: HowTo convert "seconds since `00:00:00 1970-01-01 UTC" into a human readable date"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: Thu, 15 Apr 2004 01:26:31 GMT
Hermann Peifer wrote:
> Hi All,
> I have a list with timestamps expressed as
> "seconds since `00:00:00 1970-01-01 UTC", see here:
> 1081784658
> ...
> I would like to convert them into human readable dates, e.g.
>
> 2004-04-13 20:06:37
>
> IMHO, the solution seems to be around strftime() or strptime() functions,
> but I don't manage to get it right.
>
> Any solution is welcome, preferably a simple one, e.g. a shell oneliner.
just use date :)
inode@breadbox:~$ date -d '1970-01-01 1081784658 sec' +"%Y-%m-%d %T %z"
2004-04-12 15:44:18 +0100
- Previous message: Sundaram Ramasamy: "Re: How to become a System Administrator?"
- In reply to: Hermann Peifer: "HowTo convert "seconds since `00:00:00 1970-01-01 UTC" into a human readable date"
- Next in thread: Bill Marcum: "Re: HowTo convert "seconds since `00:00:00 1970-01-01 UTC" into a human readable date"
- Reply: Bill Marcum: "Re: HowTo convert "seconds since `00:00:00 1970-01-01 UTC" into a human readable date"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]