|
|
|
@ -453,8 +453,8 @@ class VariableClUpdateSyncOverlayRep(ReadonlyVariable):
|
|
|
|
|
type = "list"
|
|
|
|
|
|
|
|
|
|
def get(self):
|
|
|
|
|
return filter(lambda x: x not in ("portage", "gentoo"),
|
|
|
|
|
self.Get('cl_update_sync_rep'))
|
|
|
|
|
return list(filter(lambda x: x not in ("portage", "gentoo"),
|
|
|
|
|
self.Get('cl_update_sync_rep')))
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
class VariableClUpdateOutdateSet(ReadonlyVariable):
|
|
|
|
@ -782,11 +782,11 @@ class VariableClUpdateProfileDependData(ReadonlyTableVariable):
|
|
|
|
|
dv = self.Get(self.datavars)
|
|
|
|
|
if dv:
|
|
|
|
|
if hr == HumanReadable.Yes:
|
|
|
|
|
return reversed(zip([x.capitalize() for x in dv.Get('cl_update_rep_name')],
|
|
|
|
|
dv.Get('cl_update_rep_url')))
|
|
|
|
|
return reversed(list(zip([x.capitalize() for x in dv.Get('cl_update_rep_name')],
|
|
|
|
|
dv.Get('cl_update_rep_url'))))
|
|
|
|
|
else:
|
|
|
|
|
return reversed(zip(dv.Get('cl_update_rep_name'),
|
|
|
|
|
dv.Get('cl_update_rep_url')))
|
|
|
|
|
return reversed(list(zip(dv.Get('cl_update_rep_name'),
|
|
|
|
|
dv.Get('cl_update_rep_url'))))
|
|
|
|
|
return ""
|
|
|
|
|
|
|
|
|
|
setValue = Variable.setValue
|
|
|
|
@ -828,7 +828,7 @@ class VariableClUpdateTemplatesLocate(Variable):
|
|
|
|
|
def choice(self):
|
|
|
|
|
descr = lambda x: self.descriptionMap.get(x,
|
|
|
|
|
_("%s overlay templates" % x))
|
|
|
|
|
return map(lambda x: (x, descr(x)), self.get())
|
|
|
|
|
return list(map(lambda x: (x, descr(x)), self.get()))
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
class VariableClUpdateProfileDependName(FieldValue, ReadonlyVariable):
|
|
|
|
@ -936,7 +936,7 @@ class VariableClUpdateProfileUrl(Variable):
|
|
|
|
|
r"^(?:(%s)://)?((?:git@)?\w[\w\./:-]+?\w)(\.git)?$" % "|".join(
|
|
|
|
|
["http", "https", "git", "ssh"]))
|
|
|
|
|
|
|
|
|
|
re_shortname = re.compile('^(?:([\w\.-]+):)?([\w\.-]+)$')
|
|
|
|
|
re_shortname = re.compile(r'^(?:([\w\.-]+):)?([\w\.-]+)$')
|
|
|
|
|
|
|
|
|
|
@classmethod
|
|
|
|
|
def normalize_url(cls, url):
|
|
|
|
@ -1094,10 +1094,10 @@ class VariableClProfileData(ReadonlyTableVariable):
|
|
|
|
|
profile_arch = [x.arch for x in filtered_profiles]
|
|
|
|
|
short_name = simplify_profiles(full_name)
|
|
|
|
|
full_name = ["%s:%s" % (repo_name, x) for x in full_name]
|
|
|
|
|
return zip(full_name,
|
|
|
|
|
return list(zip(full_name,
|
|
|
|
|
short_name,
|
|
|
|
|
profile_path,
|
|
|
|
|
profile_arch)
|
|
|
|
|
profile_arch))
|
|
|
|
|
|
|
|
|
|
setValue = Variable.setValue
|
|
|
|
|
|
|
|
|
@ -1262,12 +1262,12 @@ class VariableClUpdateProfileSystem(Variable):
|
|
|
|
|
if not url:
|
|
|
|
|
return []
|
|
|
|
|
arch = self.Get(self.gentoo_arch)
|
|
|
|
|
profiles = zip(*self.Select([self.profiles_shortname,
|
|
|
|
|
profiles = list(zip(*self.Select([self.profiles_shortname,
|
|
|
|
|
self.profiles_fullname],
|
|
|
|
|
where=self.profiles_arch, eq=arch))
|
|
|
|
|
where=self.profiles_arch, eq=arch)))
|
|
|
|
|
if profiles:
|
|
|
|
|
short_name, full_name = profiles
|
|
|
|
|
return zip(short_name, full_name)
|
|
|
|
|
return list(zip(short_name, full_name))
|
|
|
|
|
return []
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|