View Single Post
  #11 (permalink)  
Old 08-27-10, 09:03
LKBrwn_DBA LKBrwn_DBA is offline
Registered User
 
Join Date: Jun 2003
Location: West Palm Beach, FL
Posts: 2,455
Cool Recursive?

Quote:
Originally Posted by script View Post
Please Try below:-

dir1="D:\Program Files\archive"
for Dir in "$dir1"
do
cd "$Dir"
echo `pwd`
find `pwd` -mtime +1 -type f -print
done
exit 0
You do NOT need the for loop, the find command will recourse the directory tree including it's sub-directories.
__________________
The person who says it can't be done should not interrupt the person doing it. -- Chinese proverb
Reply With Quote