code: def __get_cfg_pkgs_rpm(self):
          '''
          Get packages with configuration files on RPM systems.
          '''
          out, err = self._syscall('rpm', None, None, '-qa', '--configfiles',
                                   '--queryformat', '%{name}-%{version}-%{release}\\n')
          data = dict()
          pkg_name = None
          pkg_configs = []
  
          out = salt.utils.stringutils.to_str(out)
          for line in out.split(os.linesep):
              line = line.strip()
              if not line:
                  continue
              if not line.startswith("/"):
                  if pkg_name and pkg_configs:
                      data[pkg_name] = pkg_configs
                  pkg_name = line
                  pkg_configs = []
              else:
                  pkg_configs.append(line)
  
          if pkg_name and pkg_configs:
              data[pkg_name] = pkg_configs
  
          return datf __get_cfg_pkgs_rpm(self):
          '''
          Get packages with configuration files on RPM systems.
          '''
          out, err = self._syscall('rpm', None, None, '-qa', '--configfiles',
                                   '--queryformat', '%{name}-%{version}-%{release}\\n')
          data = dict()
          pkg_name = None
          pkg_configs = []
  
          out = salt.utils.stringutils.to_str(out)
          for line in out.split(os.linesep):
              line = line.strip()
              if not line:
                  continue
              if not line.startswith("/"):
                  if pkg_name and pkg_configs:
                      data[pkg_name] = pkg_configs
                  pkg_name = line
                  pkg_configs = []
              else:
                  pkg_configs.append(line)
  
          if pkg_name and pkg_configs:
              data[pkg_name] = pkg_configs
  
          return data
docs: Get packages with configuration files on RPM systems.