I\'m using find for a task and I noticed that when I do something like this:
find `pwd` -name \"file.ext\" -exec echo $(dirname {}) \\;
it will
you do not have to call dirname() for each file found. with GNU find, you can use -printf and its faster this way
-printf
find /path -type f -iname "*.ext" -printf "%h\n"