Check for bash interactivity properly.