Create delay loop in ruby?

i am trying to run an executable file(say a.exe) which will produce a
a.log once finish.so i create the algo below to analyze the log file.

if(a.exe exist)
execute a.exe

    if(a.log exist)
      analyze a.log
     end
end

but, my thinking is the checking for a.log exist will be done way before
the a.exe is finished.

any workaround for my problem? i was thinking of using a delay(if can)
though it is not so reliable....

···

--
Posted via http://www.ruby-forum.com/.

Just invoke the process synchronously, e.g. via "system".

robert

···

2008/12/18 Xx Xx <limhuisian@hotmail.com>:

i am trying to run an executable file(say a.exe) which will produce a
a.log once finish.so i create the algo below to analyze the log file.

if(a.exe exist)
execute a.exe

   if(a.log exist)
     analyze a.log
    end
end

but, my thinking is the checking for a.log exist will be done way before
the a.exe is finished.

any workaround for my problem? i was thinking of using a delay(if can)
though it is not so reliable....

--
remember.guy do |as, often| as.you_can - without end