Thanks all, for your help. As an OLD unix type, I only thought of solving the problem in that domain. With your pointers, I learned just enough Applescript to call perl from a Folder Action. I have only done "date >>/tmp/timestame" so far, but that proves the process. I also will try to load and use the IO::Kqueue package. That looks like just the ticket for a perl-only approach. Again, thanks. --Linn ------------------------------ Greetings. On my Mac OS X machine, I would like to drag a file to a folder and as it is dropped in, to wake up my perl script. My first attempt was to create a named pipe and have my script waiting on an open function. This worked great for something like cat somefile >mynamedpipe but unfortunately, the application I wanted to export from would not write to the pipe. It needed to delete it and write a normal file. So now I am looking at alternatives. It would be easy to modify the script to process some file that has been written or dropped into a directory, but I would like to control it with something more elegant than polling the directory on a sleep timer. I searched somewhat throught CPAN but didn't see anything initially. Any ideas? Thanks.

In reply to How to do a blocking readdir or similar by bigcreeklinn

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.