find :
find -type d -exec sh -c '[ -f "$0"/index.php ] && [ -f "$0"/style.css ]' '{}' \; -print
, && [ -f "$0"/other_file ]. sh , . , sh , .
:
$ mkdir dir1
$ touch dir1/a
$ mkdir dir2
$ touch dir2/a
$ touch dir2/b
$ find -type d -exec sh -c '[ -f "$0"/a ] && [ -f "$0"/b ]' '{}' \; -print
./dir2
, dir1 dir2. dir2 , .
gniourf_gniourf (), sh. :
find -type d -exec test -f '{}'/a -a -f '{}'/b \; -print
[ test . -a && , .
, :
find -type d -exec test -f '{}'/a -a -f '{}'/b \; -print0 | tar --null -T - -cf archive.tar.bz2
-print0 , . , , . tar , bzip. , find -print0. , -print ( --null tar), .