__slots__ = ("fetchonly", "pkg",)
- _env_vars = ("FETCHCOMMAND", "GENTOO_MIRRORS", "RESUMECOMMAND")
-
def _start(self):
root_config = self.pkg.root_config
ebuild_path = portdb.findname(self.pkg.cpv)
settings = root_config.settings
- fetch_env = settings.environ()
+ fetch_env = dict(settings.iteritems())
fetch_env["PORTAGE_NICENESS"] = "0"
- for k in self._env_vars:
- v = settings.get(k)
- if v is not None:
- fetch_env[k] = v
if self.fetchonly:
fetch_env["PORTAGE_PARALLEL_FETCHONLY"] = "1"
def iterkeys(self):
return iter(self)
+ def iteritems(self):
+ for k in self:
+ yield (k, self[k])
+
+ def items(self):
+ return list(self.iteritems())
+
def __setitem__(self,mykey,myvalue):
"set a value; will be thrown away at reset() time"
if not isinstance(myvalue, str):