Comparing modified times of files

Art Neilson art at pilikia.pegasus.com
Mon Mar 11 08:04:19 AEST 1991


In article <1991Mar10.212854.3183 at pilikia.pegasus.com> art at pilikia.pegasus.com (Art Neilson) writes:
>In article <SCOTTP.91Mar8093523 at bwdlh504.bnr.ca> scottp at bwdlh504.bnr.ca (Scott Pace) writes:
>>I would like to be able to compare two files' time stamps, to see which one
>>is the oldest (or newest). How can I do this with sh?
>How about:
>
>:
>echo `ls -t $* | head -1`

After posting this I realized the echo `` part was rather useless,
it should be:

:
ls -t $* | head -1
-- 
Arthur W. Neilson III		| INET: art at pilikia.pegasus.com
Bank of Hawaii Tech Support	| UUCP: uunet!ucsd!nosc!pilikia!art



More information about the Comp.unix.shell mailing list