in reply to Detecting interactive/non-interactive shell
-t Filehandle is opened to a tty.If you test STDIN (or maybe STDOUT) with -t and it returns false you should be running from a cron. I think. If you have the perl cookbook i think there is a recipe on this. I don't have it with me. Maybe someone else does.
Formatting fixed by holli
|
|---|