~~TOC~~
Hier finden sich spezielle, oft genutzte Kommandos von find
# find files modified within the last 600 days ending with '.css' and containing 'cbecker' # show filename and line of occurency (-Hn) find . -mtime -600 -name "*.css" -exec grep -Hn cbecker {} +
# erase files/dirs older than 30 days from ${PROJECTS}/tmp/ find "${PROJECTS}/tmp/" -maxdepth 1 -mtime +30 -exec rm -rf {} \; ## move files/dirs older than 7 days into ${PROJECTS}/tmp/ ## whose name is not "BuildSlave" and "tmp" TODAY=`date "+%Y%m%d"` find "${PROJECTS}/" -maxdepth 1 -mtime +7 \ -a ! -name "BuildSlave" -a ! -name "tmp" \ -exec mv {} "${PROJECTS}/tmp/$TODAY" ;