If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > Data Access, Manipulation & Batch Languages > Unix Shell Scripts > old files compare date

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 05-20-04, 22:39
chatguy2020 chatguy2020 is offline
Registered User
 
Join Date: May 2003
Posts: 58
old files compare date

Hi, the below command searches for files older than today in a directory and also subdirectories. I want to restrict the search to the current directory only. Any ideas? Thanks
find /path/to/search -type f -mtime +1.
Reply With Quote
  #2 (permalink)  
Old 05-20-04, 22:56
vgersh99 vgersh99 is offline
Registered User
 
Join Date: Apr 2004
Location: Boston, MA
Posts: 325
'man find' and search for 'prune'

find /path/to/search -type f -mtime +1 -prune
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On