On 0, Shawn McMahon <[EMAIL PROTECTED]> wrote: > begin quoting what Karsten M. Self said on Mon, Apr 08, 2002 at 10:18:58AM > -0700: > > > > Not recommended. If X quits abnormally, it will also restart. What you > > want: > > > > startx_command && shutdown -h now > > > > ...which should only restart the system if X is exited normally. If it > > exits with a nonzero status, the system stays up. > > Stays up at a shell prompt. It's a kiosk, remember? > > Shell prompt == bad. Restart == less bad.
So...
while 0 ; do
startx_command && shutdown -h now ;
done
will only shutdown when startx_command exits with error 0, otherwise
it'll restart.
Tom
--
Tom Cook
Information Technology Services, The University of Adelaide
"That you're not paranoid does not mean they're not out to get you."
- Robert Waldner
Get my GPG public key:
https://pinky.its.adelaide.edu.au/tom.cook-at-adelaide.edu.au
pgpBnievxz8cS.pgp
Description: PGP signature

