[Date Prev][Date Next][Thread Prev][Thread Next] [Search] [Date Index] [Thread Index]

Re: [MacPerl] Unix daemons in Perl on MacOS?



hello,

while not a MacPerl only solution, how about a stay open applescript that
calls a MacPerl script?  The example is a script that sleeps for 5 seconds,
then does something.  A stay open applescript can call a perl script every
5 seconds.  For user feedback, Mac::PerlAnswer is ok, but there is no built
in timeout for the dialog.  As of OS9, the applescript display dialog has
an option "giving up after" x seconds, which can be called using Mac::Glue.
 Just a thought.


At 02:45 PM 1/25/00 , Brian McNett wrote:
>
>Jonathan Eisenzopf ends his regular "Mother of Perl" column:
>
>http://webreference.com/perl/tutorial/9/
>
>which is on the subject of writing Unix daemon processes in Perl,
>
>with a the following plaint:
>
>> Maybe someone who has a Mac will send me a version that will run on MacOS.
>
>Okay, I'm admittedly sckeptical that there even *is* such a beast.  
>However, there's the possiblity of a copy of "Mastering Algorithms in 
>Perl" (which I really need and really can't afford), to spur me on.
>
>So...  To tackle this, the closest I can come conceptually is a "faceless 
>background app".
>
>Jon's example is a simple daemon that prints "hello" to the console every 
>five seconds or so. Since there's no console on the Mac (outside of just 
>sending the output to STDOUT in MacPerl), and we WANT the application to 
>remain hidden when it's not doing it's thing, I suspect MacPerl::Answer 
>to be a fair workaround.
>
>Aside from that, the application has to hand back control to other 
>running apps when it's not active (sound's like a Mac Toolbox job to me).
>
>I've no code yet, but I'm hoping to get some sort of discussion going 
>here to give me ideas of where to go with this.
>
>--B
>
>Brian McNett, Webmaster
>*************************************************************
>Mycoinfo. The world's first mycology e-journal.
>http://www.mycoinfo.com/
>*************************************************************
>
>
># ===== Want to unsubscribe from this list?
># ===== Send mail with body "unsubscribe" to macperl-request@macperl.org
>

 ________________________________________________________
| Enrique Terrazas, MD      |    UCSF                    |
| phone:  (415) 502-5420    |    Dept. of Lab Medicine   |       
| beeper: (415) 719-6626    |    Room C-250              |
|___________________________|____________________________|
|          <mailto:terrazas@labmed.ucsf.edu>             |
|         <http://labmed.ucsf.edu/~terrazas/>            |
|________________________________________________________|

# ===== Want to unsubscribe from this list?
# ===== Send mail with body "unsubscribe" to macperl-request@macperl.org