これは私のフォルダ構造です:
/site1/myFolder/otherFolder1/a.gif
/site1/myFolder/otherFolder1/b.png
/site1/myFolder/otherFolder1/c.php
...
/site2/myFolder/otherFolder2/d.gif
/site2/myFolder/otherFolder2/e.png
/site2/myFolder/otherFolder2/f.php
...
/site3/myFolder/otherFolder3/g.gif
/site3/myFolder/otherFolder3/h.png
/site3/myFolder/otherFolder3/i.php
...
ここまで来ました:
find /var/www/html -type d -name myFolder -exec find {} -name "*.php" \;
for i in `find /var/www/html -type d -name myFolder -exec find {} -name "*.php" \;`
do
some_house_keeping_here
done
しかし、私はこのようなことをしたい:
find /var/www/html -type d -name myFolder -exec find {} -name "*.php" -exec do_some_housekeeping {} \; \;