On Tue, Aug 09, 2005 at 10:07:41PM -0500, Nathan Stratton Treadway wrote: > Package: popularity-contest > Version: 1.28 > Severity: wishlist > > > I was interested in converting the atime and ctime "time_t" integers found > in my popularity contest reports into a human-readable date. I eventually > ran across the "ctime()" function in Python's "time" module which did the > conversion I wanted, but I wasn't able to find any "simple" command line > utility that was able to convert in that direction. > > (For example, the "date" command's %s format directive will return the > time_t integer for the date being displayed, but the --date= option > doesn't seem to let me specify a date using the time_t integer.)
IMHO, this should rather be reported as a wishlist to the date utility. You can use date -d "$((`date +%s` - $DATE )) seconds ago" or perl -e 'print scalar localtime '$DATE',"\n"' where $DATE is the the date you want to convert. Cheers, -- Bill. <[EMAIL PROTECTED]> Imagine a large red swirl here. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

