> It doesn't appear so to me. > > [steve@sylar ~]$ tty > /dev/pts/16 > [steve@sylar ~]$ setsid tty > /dev/pts/16 > > [steve@sylar ~]$ python -c "import sys,os; print > os.isatty(sys.stdout.fileno())" > True > [steve@sylar ~]$ setsid python -c "import sys,os; print > os.isatty(sys.stdout.fileno())" > True > > > If I run the same Python command (without the setsid) as a cron job, I > get False emailed to me. That's the effect I'm looking for. > > Maybe nohup is what you looking for?
>From the info pages... "`nohup' runs the given COMMAND with hangup signals ignored, so that the command can continue running in the background after you log out. Synopsis: nohup COMMAND [ARG]... If standard output is a terminal, it is redirected so that it is appended to the file `nohup.out'; if that cannot be written to, it is appended to the file `$HOME/nohup.out'. If that cannot be written to, the command is not run. If standard output is not a terminal, then the standard output of COMMAND will be the same as that of `nohup'. " Regards Bradley
-- http://mail.python.org/mailman/listinfo/python-list