Operating System - HP-UX
1832988 Members
2384 Online
110048 Solutions
New Discussion

list the files with seconds

 
HartfordBala1973
Occasional Advisor

list the files with seconds

I would like to list the files including seconds, please let us know if there is a option in 11i.

Thanks
bala
6 REPLIES 6
AwadheshPandey
Honored Contributor

Re: list the files with seconds

try this

perl -e 'foreach(@ARGV){$t =localtime ( ( ( stat ( $_ ) ) [9] ) ); printf("%-20s%s\n",$_,$t);}' *

It's kind of fun to do the impossible
HartfordBala1973
Occasional Advisor

Re: list the files with seconds

Thanks Awadesh
HartfordBala1973
Occasional Advisor

Re: list the files with seconds

Also can we display the files in mill seconds, is that possible?

Thanks
bala
HartfordBala1973
Occasional Advisor

Re: list the files with seconds

Can anyone reply on this?

Thanks
bala
Dennis Handly
Acclaimed Contributor

Re: list the files with seconds

(I'll ask this be moved to the HP-UX forums.)

>can we display the files in milliseconds, is that possible?

No, files only track time_t, in seconds.
Dennis Handly
Acclaimed Contributor

Re: list the files with seconds

You have not assigned any points yet. Please read:
http://forums1.itrc.hp.com/service/forums/helptips.do?#33