Home Explore Blog CI



man-pages

5th chunk of `find.man`
280df6a2763aa3faa7683eff81c1136c1676d1cf3ad99d310000000100000fa9
 expression dialect for regular
              expressions occurring later on the command line.

       Operators
              Operators join together the other items within the expression.  They include for example -o (meaning logical OR) and -a (meaning logical AND).  Where an operator is missing, -a is assumed.

       The -print action is performed on all files for which the whole expression is true, unless it contains an action other than -prune or -quit.  Actions which inhibit the default -print are -delete, -exec, -execdir, -ok,
       -okdir, -fls, -fprint, -fprintf, -ls, -print and -printf.

       The -delete action also acts like an option (since it implies -depth).

   POSITIONAL OPTIONS
       Positional options always return true.  They affect only tests occurring later on the command line.

       -daystart
              Measure times (for -amin, -atime, -cmin, -ctime, -mmin, and -mtime) from the beginning of today rather than from 24 hours ago.  This option only affects tests which appear later on the command line.

       -follow
              Deprecated; use the -L option instead.  Dereference symbolic links.  Implies -noleaf.  The -follow option affects only those tests which appear after it on the command line.  Unless the -H or -L option has been
              specified,  the  position of the -follow option changes the behaviour of the -newer predicate; any files listed as the argument of -newer will be dereferenced if they are symbolic links.  The same consideration
              applies to -newerXY, -anewer and -cnewer.  Similarly, the -type predicate will always match against the type of the file that a symbolic link points to rather than the link itself.   Using  -follow  causes  the
              -lname and -ilname predicates always to return false.

       -regextype type
              Changes the regular expression syntax understood by -regex and -iregex tests which occur later on the command line.  To see which regular expression types are known, use -regextype help.  The Texinfo documenta‐
              tion (see SEE ALSO) explains the meaning of and differences between the various types of regular expression.

       -warn, -nowarn
              Turn  warning  messages on or off.  These warnings apply only to the command line usage, not to any conditions that find might encounter when it searches directories.  The default behaviour corresponds to -warn
              if standard input is a tty, and to -nowarn otherwise.  If a warning message relating to command‐line usage is produced, the exit status of find is not affected.  If the POSIXLY_CORRECT environment  variable  is
              set, and -warn is also used, it is not specified which, if any, warnings will be active.

   GLOBAL OPTIONS
       Global options always return true.  Global options take effect even for tests which occur earlier on the command line.  To prevent confusion, global options should specified on the command‐line after the list of start
       points, just before the first test, positional option or action.  If you specify a global option in some other place, find will issue a warning message explaining that this can be confusing.

       The global options occur after the list of start points, and so are not the same kind of option as -L, for example.

       -d     A synonym for -depth, for compatibility with FreeBSD, NetBSD, MacOS X and OpenBSD.

       -depth Process each directory’s contents before the directory itself.  The -delete action also implies -depth.

       -files0-from file
              Read  the  starting points from file instead of getting them on the command line.  In contrast to the known limitations of passing starting points via arguments on the command line, namely the limitation of the
              amount of file names, and the inherent ambiguity of file names clashing with option names, using this option allows to safely pass an arbitrary number of starting points to find.

              Using

Title: find Positional and Global Options
Summary
This section explains positional options in `find`, which affect only tests occurring later on the command line, and global options, which affect all tests regardless of their position. Positional options covered include `-daystart`, `-follow`, `-regextype`, and `-warn`/`-nowarn`. Global options described are `-d` (synonym for `-depth`), `-depth`, and `-files0-from file`.