Added comments to main.py

Also rearranged the external_enabled and main_dir sections