home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #27 / NN_1992_27.iso / spool / comp / unix / shell / 4842 < prev    next >
Encoding:
Text File  |  1992-11-22  |  1.2 KB  |  39 lines

  1. Newsgroups: comp.unix.shell
  2. Path: sparky!uunet!mcsun!sunic!ericom!eos.ericsson.se!etxmesa
  3. From: etxmesa@eos.ericsson.se (Michael Salmon)
  4. Subject: Re: Last modification time for a directory -- How?
  5. Message-ID: <1992Nov23.100217.2220@ericsson.se>
  6. Sender: news@ericsson.se
  7. Nntp-Posting-Host: eos6c02.ericsson.se
  8. Reply-To: etxmesa@eos.ericsson.se (Michael Salmon)
  9. Organization: Ericsson Telecom AB
  10. References:  <1epmvvINN1b1@agate.berkeley.edu>
  11. Date: Mon, 23 Nov 1992 10:02:17 GMT
  12. Lines: 25
  13.  
  14. In article <1epmvvINN1b1@agate.berkeley.edu>, ilan343@violet.berkeley.edu (Geraldo Veiga) writes:
  15. |> A question:
  16. |> 
  17. |> How do I find the last modification time for a directory, meaning what
  18. |> was the last modification time for any file under the directory.
  19. |> 
  20. |> More specifically, I would like to determine in a shell script, which
  21. |> of 2 directories was modified last.  Just looking at ls output is not
  22. |> enough, since it doesn't reflect the modification tile of file in the
  23. |> directory's down tree.
  24. |> 
  25. |> Any hints on how I do this? 
  26.  
  27. Use ls -ltA and use the modification time of the first entry.
  28.  
  29. -- 
  30.  
  31. Michael Salmon
  32.  
  33. #include    <standard.disclaimer>
  34. #include    <witty.saying>
  35. #include    <fancy.pseudo.graphics>
  36.  
  37. Ericsson Telecom AB
  38. Stockholm
  39.