Disable logging to stderr if it is not a tty