Linux Bash If Variable Not Defined In Python