|
|
|
@ -448,15 +448,36 @@ class VariableClUpdateSettingsChangesSet(Variable):
|
|
|
|
|
Определить были ли изменения в /etc/portage, /var/log/emerge.log
|
|
|
|
|
"""
|
|
|
|
|
type = Variable.Types.Boolean
|
|
|
|
|
value = ''
|
|
|
|
|
|
|
|
|
|
def get(self):
|
|
|
|
|
if self.value:
|
|
|
|
|
return self.value
|
|
|
|
|
ini = SystemIni(self.parent)
|
|
|
|
|
old_portage_state_hash = ini.getVar('system', 'portage_hash') or ""
|
|
|
|
|
ps = PortageState()
|
|
|
|
|
new_portage_state_hash = ps.get_state()
|
|
|
|
|
a = new_portage_state_hash != old_portage_state_hash
|
|
|
|
|
return "on" if new_portage_state_hash != old_portage_state_hash else "off"
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
class VariableClUpdateSettingsPortageSet(Variable):
|
|
|
|
|
"""
|
|
|
|
|
Определить были ли изменения в /etc/portage
|
|
|
|
|
"""
|
|
|
|
|
type = Variable.Types.Boolean
|
|
|
|
|
value = ''
|
|
|
|
|
|
|
|
|
|
def get(self):
|
|
|
|
|
if self.value:
|
|
|
|
|
return self.value
|
|
|
|
|
ini = SystemIni(self.parent)
|
|
|
|
|
old_portage_state_hash = ini.getVar('system', 'portage_hash') or ""
|
|
|
|
|
ps = PortageState()
|
|
|
|
|
new_portage_state_hash = ps.get_state()
|
|
|
|
|
a = new_portage_state_hash != old_portage_state_hash
|
|
|
|
|
return "on" if new_portage_state_hash != old_portage_state_hash else "off"
|
|
|
|
|
|
|
|
|
|
class VariableClUpdateBranchName(Variable):
|
|
|
|
|
"""
|
|
|
|
|
Список доступных репозиторием
|
|
|
|
@ -532,9 +553,9 @@ class VariableClUpdateOutdateSet(ReadonlyVariable):
|
|
|
|
|
type = "bool"
|
|
|
|
|
|
|
|
|
|
def get(self):
|
|
|
|
|
if (self.Get('cl_update_other_set') == 'on' and
|
|
|
|
|
self.Get('cl_update_other_rep_name')):
|
|
|
|
|
return "on"
|
|
|
|
|
# if (self.Get('cl_update_other_set') == 'on' and
|
|
|
|
|
# self.Get('cl_update_other_rep_name')):
|
|
|
|
|
# return "on"
|
|
|
|
|
return "off"
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@ -636,37 +657,19 @@ class VariableClUpdateOtherSet(Variable):
|
|
|
|
|
"""
|
|
|
|
|
Обновить остальные оверлеи
|
|
|
|
|
"""
|
|
|
|
|
type = "bool"
|
|
|
|
|
value = "on"
|
|
|
|
|
metavalue = _("Other overlays")
|
|
|
|
|
type = "boolauto"
|
|
|
|
|
opt = ["-o", "--update-other"]
|
|
|
|
|
metavalue = _("ON/OFF/AUTO")
|
|
|
|
|
value = Variable.Auto
|
|
|
|
|
|
|
|
|
|
def init(self):
|
|
|
|
|
self.label = _("Update other overlays")
|
|
|
|
|
self.help = _("Update other overlays")
|
|
|
|
|
self.help = _("Update other overlays. Updates other overlays while updating default overlays if value is not specified")
|
|
|
|
|
|
|
|
|
|
def get(self):
|
|
|
|
|
if self.Get('cl_update_inner_other_set') != 'auto':
|
|
|
|
|
return self.Get('cl_update_inner_other_set')
|
|
|
|
|
return self.value
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
class VariableClUpdateInnerOtherSet(Variable):
|
|
|
|
|
type = "bool3"
|
|
|
|
|
value = Variable.Auto
|
|
|
|
|
metavalue = 'ON/OFF'
|
|
|
|
|
opt = ["-o", "--update-other"]
|
|
|
|
|
|
|
|
|
|
def init(self):
|
|
|
|
|
self.help = _("update other overlays")
|
|
|
|
|
self.label = _("Update other overlays")
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
# def get(self):
|
|
|
|
|
# if self.value in ["on", "off"]:
|
|
|
|
|
# return True
|
|
|
|
|
# return False
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
class VariableClUpdateOtherRepData(ReadonlyTableVariable):
|
|
|
|
|
"""
|
|
|
|
|
Информация о прочих репозиториях
|
|
|
|
@ -2046,4 +2049,4 @@ class VariableClUpdateSavedTag(Variable):
|
|
|
|
|
"""
|
|
|
|
|
Сохраняемый тэг репозитория calculate
|
|
|
|
|
"""
|
|
|
|
|
type = "int"
|
|
|
|
|
type = "int"
|
|
|
|
|