See Re: Are you looking at XML processing the right way? (merge) for why callbacks are fundamentally worse than several other interfaces.

Another problem with File::Find's interface is that the order in which you get things isn't always the order you want or expect. You also don't get told when you go down or up a level.

I find that it is often easier for me to just write a directory searcher than to figure out how to do what I want with File::Find (since I will make the decisions about exactly what order to do things and when I go up and down a level is clear).

And remember that you always want to set $dont_use_nlink unless you are only interested in file names, not any file properties.

- tye        


In reply to Re: File::Find considered hard? (callbacks) by tye
in thread File::Find considered hard? by Jenda

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.