Beefy Boxes and Bandwidth Generously Provided by pair Networks
The stupid question is the question not asked

Re: Pause Perl Script Execution

by oxone (Friar)
on Sep 08, 2007 at 15:25 UTC ( #637842=note: print w/replies, xml ) Need Help??

in reply to Pause Perl Script Execution

Assuming the file in question will be created by something external to your Perl script and you just want to wait:
sleep 1 while !-e 'myfile.txt';
Note that !-e means "file doesn't exist". This will keep looping and checking every 1 second forever, and move on only if the relevant file appears.

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://637842]
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others romping around the Monastery: (9)
As of 2016-10-26 15:36 GMT
Find Nodes?
    Voting Booth?
    How many different varieties (color, size, etc) of socks do you have in your sock drawer?

    Results (342 votes). Check out past polls.