Fun with find

# find all .html files in the current directory and sub directories
find . -name "*.html" -type f -print

# find all "dot" directories
find /Users/smbrown -name ".*" -type d -print

# find all "dot" files
find /Users/smbrown -name ".*" -type f -print

# find all dot files, but omit the pesky OS X .DS_Store files
find . -name ".*" -type f ! -name ".DS_Store"
# find all the .mp3 files in the cwd and copy them to a folder on the desktop named iPod
find . -name "*.m*" -type f -exec cp '{}' ~/Desktop/iPod/ \;

Leave a comment