find test conditions
  • -test-option test-condition - determines parameter[s] to use to recognize file of interest.
    compounding test conditions

  • -a AND - test for success of test-condition.

  • -o OR - test for failure of test-condition.

  • ( ) parentheses - groups tests for correct interpretation. Will need \ to hide from command interpreter.

  • ! NOT - Invert test result. Will need \ to hid from command interpeter.

    find . \! -name "backups" -a \! -name "evals" -print

    find . \! \( -name backups -o -name evals \) -print

    These 2 are the same.

    These will print every files except files named backups or evals. This is not the same as -prune which will be covered under actions.

    Because both ! and () are shell expressions, backslash is required to pass them unprocessed to the find command.


    There are several other test conditions. See man find The man page on find is one of the better man pages on the system. It includes a whole section of examples.

    find actions