Difference between revisions of "Find"
From Knoppix Documentation Wiki
(Init from PHPWiki) |
(No difference)
|
Revision as of 23:46, 25 September 2005
find is a powerful Linux command used to locate files in many ways.
Note: This is perhaps the most complex (grammatically) Unix command there is. Don't worry if it looks confusing. Few Linux pros really know all the ins and outs of it, either.
Examples
find . -print
Locate all files, links, and directories.
find . -name '.txt' -print
Locate all files named .txt, from current dirctory.
[[find /home/knoppix -name '*.bak' -print
Locate all files in other directory, as above.
find . -daystart -cmin -3660 -cmin +0 -name '.txt' -print
Locate all files, named .txt, and have changed yesterday.
find . --maxdepth 1 -type f -print
Locate all "only" files in current directory.
Yes, the grammar and switches can get quite intense.
Where do you find this stuff? If man pages don't have enough examples. Try linux help sites, the old guy's Unix books, or FAQ Unix command web searches.