docs: def get_env_dict(root_section):
      """Read all Lago variables from the environment.
      The lookup format is:
      LAGO_VARNAME - will land into 'lago' section
      LAGO__SECTION1__VARNAME - will land into 'section1' section, notice
      the double '__'.
      LAGO__LONG_SECTION_NAME__VARNAME - will land into 'long_section_name'
  
  
      Returns:
          dict: dict of section configuration dicts
  
      Examples:
          >>> os.environ['LAGO_GLOBAL_VAR'] = 'global'
          >>> os.environ['LAGO__INIT__REPO_PATH'] = '/tmp/store'
          >>>
          >>> config.get_env_dict()
          {'init': {'repo_path': '/tmp/store'}, 'lago': {'global_var': 'global'}}
  
      """
      env_lago = defaultdict(dict)
      decider = re.compile(
          (
              r'^{0}(?:_(?!_)|(?P<has>__))'
              r'(?(has)(?P<section>.+?)__)'
              r'(?P<name>.+)$'
          ).format(root_section.upper())
      )
  
      for key, value in os.environ.iteritems():
          match = decider.match(key)
          if not match:
              continue
          if not match.group('name') or not value:
              warn(
                  'empty environment variable definition:'
                  '{0}, ignoring.'.format(key)
              )
          else:
              section = match.group('section') or root_section
              env_lago[section.lower()][match.group('name').lower()] = value
      return dict(env_lago)