mirror of
https://github.com/Dev-Wiki/git-repo.git
synced 2025-12-13 16:14:02 +08:00
manifest: add submanifest.default_groups attribute
When the user does not specify any manifest groups, this allows the parent manifest to indicate which manifest groups should be used for syncing the submanifest. Change-Id: I88806ed35013d13dd2ab3cd245fcd4f9061112c4 Reviewed-on: https://gerrit-review.googlesource.com/c/git-repo/+/335474 Tested-by: LaMont Jones <lamontjones@google.com> Reviewed-by: Mike Frysinger <vapier@google.com>
This commit is contained in:
@@ -715,7 +715,8 @@ class Project(object):
|
||||
The special manifest group "default" will match any project that
|
||||
does not have the special project group "notdefault"
|
||||
"""
|
||||
expanded_manifest_groups = manifest_groups or ['default']
|
||||
default_groups = self.manifest.default_groups or ['default']
|
||||
expanded_manifest_groups = manifest_groups or default_groups
|
||||
expanded_project_groups = ['all'] + (self.groups or [])
|
||||
if 'notdefault' not in expanded_project_groups:
|
||||
expanded_project_groups += ['default']
|
||||
@@ -3496,7 +3497,7 @@ class ManifestProject(MetaProject):
|
||||
"""
|
||||
assert _kwargs_only == (), 'Sync only accepts keyword arguments.'
|
||||
|
||||
groups = groups or 'default'
|
||||
groups = groups or self.manifest.GetDefaultGroupsStr(with_platform=False)
|
||||
platform = platform or 'auto'
|
||||
git_event_log = git_event_log or EventLog()
|
||||
if outer_manifest and self.manifest.is_submanifest:
|
||||
|
||||
Reference in New Issue
Block a user