def create_next_subsite(pelican_obj):
 global _MAIN_SETTINGS
 if (len(_SUBSITE_QUEUE) == 0):
  _LOGGER.debug('i18n: Updating cross-site links and context of all generators.')
  update_generators()
  _MAIN_SETTINGS = None
 else:
  with temporary_locale():
   settings = _MAIN_SETTINGS.copy()
   (lang, overrides) = _SUBSITE_QUEUE.popitem()
   settings.update(overrides)
   settings = configure_settings(settings)
   cls = get_pelican_cls(settings)
   new_pelican_obj = cls(settings)
   _LOGGER.debug("Generating i18n subsite for language '{}' using class {}".format(lang, cls))
   new_pelican_obj.run()

def create_next_subsite ( pelican_obj ) : global _MAIN_SETTINGS if ( len ( _SUBSITE_QUEUE ) == 0 ) : _LOGGER . debug ( 'i18n: Updating cross-site links and context of all generators.' ) update_generators ( ) _MAIN_SETTINGS = None else : with temporary_locale ( ) : settings = _MAIN_SETTINGS . copy ( ) ( lang , overrides ) = _SUBSITE_QUEUE . popitem ( ) settings . update ( overrides ) settings = configure_settings ( settings ) cls = get_pelican_cls ( settings ) new_pelican_obj = cls ( settings ) _LOGGER . debug ( "Generating i18n subsite for language '{}' using class {}" . format ( lang , cls ) ) new_pelican_obj . run ( )
create the next subsite using the lang-specific config if there are no more subsites in the generation queue .