Difference between revisions 507815 and 507816 on knwiki

{{otheruses}}
{{lowercase|title=find}} 

The <code>'''find'''</code> program is a [[directory (file systems)|directory]] [[search utility]], found on [[DOS]], [[Microsoft Windows|Windows]] and [[Unix-like]] platforms. It searches through one or more directory [[tree (computing)|trees]] of a [[filesystem]], locating [[Computer file|file]]s based on some user-specified criteria. By default, <code>find</code> returns all files below the current [[working di(contracted; show full)

Note that the command itself should *not* be quoted; otherwise you get error messages like

 find: echo "mv ./3bfn rel071204": No such file or directory

which mean
s that '''find''' is trying to run a file called 'echo "mv ./3bfn rel071204"' and failing.

===Search for a string===
This command will search for a string in all files from the /tmp directory and below:

 find /tmp -exec grep "search string" '{}' /dev/null \; -print

(contracted; show full)
[[de:Find]]
[[es:Find]]
[[hu:Find]]
[[ja:Find]]
[[pl:Find]]
[[pt:Find]]
[[ru:Find]]