code: def add_sources_from_file(file_name, update=True):
      
  
      key_regex = re.compile(r'(?P<source>[^()]*)(\s+\((?P<key>.*)\))?$')
      for line in _read_lines_from_file(file_name):
          kwargs = key_regex.match(line).groupdict()
          kwargs['update'] = False
          add_apt_source(**kwargs)
      if update:
          update_apt_sources()
docs: Add source urls from a file list.
      The file should contain the source line to add followed by the
      key url, if any, enclosed in parentheses.
  
      Ex:
      deb http://example.com/deb lucid main (http://example.com/key)