Difference between revisions 507857 and 507858 on knwiki

{{otheruses}}
{{lowercase|title=find}} 
The <code>'''find'''</code> program is a [[directory (file systems)|directory]] [[Search_engine_(computing)|search utility]] on [[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 directory]]. Further, <c(contracted; show full)

== Find syntax ==
{{expand-section|date=August 2008}}

<code>'''find [-H] [-L] [-P] [path...] [expression]'''</code>


PAt least one paths must precede the expressions.  Find is capable of interpreting [[Wildcard_character|wildcards]] internally and commands must be constructed carefully in order to control [[Glob_(programming)|shell globbing]].

Expression elements are whitespace-separated and evaluated from left to right.  They can contain logical elements such as AND (-a) and OR (-o) as well as more complex predicates.

The [[GNU_findutils|GNU]] find has a large number of additional features not specified inby POSIX.

== POSIX protection from infinite output ==

Real-world filesystems often contain looped structures created through the use of [[hard link|hard]] or [[symbolic link|soft links]].  The [[POSIX|POSIX standard]] requires that
 The find utility shall detect infinite loops; that is, entering a previously visited
 directory that is an ancestor of the last file encountered. When it detects an infinite
 loop, find shall write a diagnostic message to standard error and shall either recover
(contracted; show full)[[fr:Find]]
[[it:Find (Unix)]]
[[hu:Find]]
[[ja:Find]]
[[pl:Find]]
[[pt:Find]]
[[ru:Find]]
[[fi:Find (Unix)]]