Its often said that File::Find has a horrible interface. I'm curious why people think this, and how they think it could be improved.
Well - I wouldn't go as far as horrible. Insufficiently abstracted maybe. I find File::Find::Rule much more useful most of the time because:
- I don't have to mess around with long global vars like $File::Find::name
- I don't have to write any code for the common case of collecting all the matching results
- I have a declarative style that I find much easier to read and maintain
- I can never remember how no_chdir, follow and follow_fast affects the behaviour of the $_ and the $File::Find::* variables without referring to the docs.
- F::F::R makes it easy for me to compose rules
- Changing directories by default is wrong for me most of the time.