Finding files or directories
by Sanju[ Edit ] 2009-11-11 16:04:19
Finding files or directories
To locate the file 'filename', searching all the subdirectories of the current directory:
find . -name 'filename'
You can use a pattern in place of 'filename', e.g. to return the list of all .doc files in the current directory and its subdirectories:
find . -name '*.doc'
The 'find' command can do much more. For example, to find the files that were accessed yesterday:
find ~ -daystart -type f -atime 1
Consult 'info find' for more information.