(command1 &);(command2 &) sleep 10 killall command1 killall command2
perhaps? On Feb 12, 2008 5:29 PM, willhill <[EMAIL PROTECTED]> wrote: > I'd like to use a shell script to start two process at once, wait a while > and > then kill them both. Starting them manually, I'd just use the & > redirector > but I can't figure out how to do the same thing in a script. When I try > it, > the script waits for one job to be finished. For example: > > kwrite & > konqueror & > sleep 5 > killall kwrite > killall konqueror > > won't start konqueror till I kill kwrite manually and the sleep does not > start > until konqueror is finished, then I kill processes that don't exist. > > I poked around Google for a while and Linux in a nutshell but found > nothing > but fork bombs. There has got to be a better way. > > _______________________________________________ > General mailing list > [email protected] > http://mail.brlug.net/mailman/listinfo/general_brlug.net > -- Adam Melancon
_______________________________________________ General mailing list [email protected] http://mail.brlug.net/mailman/listinfo/general_brlug.net
