Exiting script with error code 1 when a needed file is not found