[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[ale] Quick script question
- Subject: [ale] Quick script question
- From: ale at politicalpurpose.com (Douglas Bridges)
- Date: Mon, 3 Mar 2003 23:18:52 -0500
The PID=$! and wait command were the trick. It took some judicious use of the
sleep command to let everything clean up good, but that did it.
Thanks!
On Monday 03 March 2003 10:59 pm, Danny Cox wrote:
>
> How about:
>
> $ARGS="some args"
> while : # always true
> do
> gui_start_proggy $ARGS &
> PID=$!
> sleep 3 # sleep 2 may only get you 1.1 secs
> if [ -d /proc/$PID ]
> then
> exit # GUI started
> else
> wait $PID # reap the child
> ARGS=$(permute $ARGS)
> fi
> done
>
> or something like that. ;-)
_______________________________________________
Ale mailing list
Ale at ale.org
http://www.ale.org/mailman/listinfo/ale