Изменена синхронизация репозиториев

Синхронизация до тегов выполняется только если включена переменная
cl_update_usetag_set.
master-3.5 3.5.6
parent 53669b7f71
commit 572ab1de99

@ -202,14 +202,16 @@ class ClUpdateAction(Action):
'message':
__("Fallback syncing the {eachvar:capitalize} repository"),
'method': 'Update.syncRepositories(eachvar,True)',
'condition': lambda Get: ("getbinpkg" in Get('cl_features') and
not Get('cl_update_binhost_data')[0])
'condition': lambda Get,GetBool: (
GetBool('cl_update_usetag_set') and
not Get('cl_update_binhost_data')[0])
},
# обновление переменных информации из binhost
{'name': 'update_binhost_list',
'method': 'Update.update_binhost_list()',
'condition': lambda Get: ("getbinpkg" in Get('cl_features') and
not Get('cl_update_binhost_data')[0])
'condition': lambda Get,GetBool: (
GetBool('cl_update_usetag_set') and
not Get('cl_update_binhost_data')[0])
},
{'name': 'sync_reps',
'foreach': 'cl_update_sync_rep',
@ -219,7 +221,7 @@ class ClUpdateAction(Action):
},
{'name': 'check_binhost',
'method': 'Update.check_binhost()',
'condition': lambda Get: "getbinpkg" in Get('cl_features')
'condition': lambda GetBool: GetBool('cl_update_usetag_set')
},
{'name': 'sync_other_reps',
'foreach': 'cl_update_other_rep_name',
@ -285,8 +287,8 @@ class ClUpdateAction(Action):
'method': 'Update.download_packages(cl_update_portage_binhost,'
'cl_update_package_cache)',
'essential': False,
'condition': lambda Get: (
"getbinpkg" in Get('cl_features') and
'condition': lambda Get, GetBool: (
GetBool('cl_update_usetag_set') and
Get('cl_update_package_cache') and (
Get('cl_update_outdate_set') == 'on' or
Get('cl_update_package_cache_set') == 'on'))

@ -238,7 +238,8 @@ class VariableClUpdateRepRev(Variable):
class VariableClUpdateBranch(Variable):
"""
Ветка на которую будет обновляться репозиторий если -getbinpkg
Ветка на которую будет обновляться репозиторий если
не используется синхронизация по тэгам
"""
value = Git.Reference.Master
@ -449,7 +450,7 @@ class VariableClUpdateBranchName(Variable):
Git.Reference.Update]
def get(self):
if "getbinpkg" in self.Get('cl_features'):
if self.GetBool('cl_update_usetag_set'):
return [Git.Reference.Tag for x in self.Get('cl_update_rep_name')]
else:
branch = self.Get('cl_update_branch')
@ -1334,6 +1335,7 @@ class DataVarsUpdateProfile(SimpleDataVars):
VariableClUpdateRepRev(section="update"),
VariableClUpdateBranch(section="update"),
VariableClUpdateBranchName(section="update"),
VariableClUpdateUsetagSet(section="update"),
VariableClUpdateLaymanConfig(section="update"),
VariableClUpdateLaymanStorage(section="update"),
VariableClUpdateRepName(section="update"),
@ -1734,15 +1736,15 @@ class VariableClUpdateWithBdepsSet(Variable):
"""
Добавление --with-bdeps при вызове emerge
"""
type = "bool"
value = "off"
type = Variable.Types.Boolean
value = Variable.Off
class VariableClUpdateWithBdepsOptSet(Variable):
"""
Добавление --with-bdeps при вызове emerge (опция)
"""
type = "bool"
type = Variable.Types.Boolean
opt = ["--with-bdeps"]
def init(self):
@ -1757,5 +1759,13 @@ class VariableClUpdateForceDepcleanSet(Variable):
"""
Принудительный вызов depclean
"""
type = "bool"
value = "off"
type = Variable.Types.Boolean
value = Variable.Off
class VariableClUpdateUsetagSet(Variable):
"""
Использовать тэги при синхронизации репозиториев
"""
type = Variable.Types.Boolean
value = Variable.On

Loading…
Cancel
Save