| Code |
Description |
| find -L . -name "*mp3" |
Find all mp3 files. Follow symbolic links to other directories. |
| find . -name roger.txt |
Find the file roger.txt in or below the current directory. |
| find . -name "*name*" -print |
Find files containing the string "name" in or below the current directory. |
| find . -user root ! -group wheel |
Find files owned by root that are not in the wheel group |
| find . -name "*.shtml" -user root -exec chown www {} \; |
Find 'shtml' files own by root and change their ownership to www |
| find . -name "*.dat" -exec sh -c 'grep ID $1 | wc -l' {} {} \; |
find -exec command pipe command |