diff options
author | LaMont Jones <lamontjones@google.com> | 2022-02-14 17:48:31 +0000 |
---|---|---|
committer | LaMont Jones <lamontjones@google.com> | 2022-02-15 22:15:42 +0000 |
commit | 87cce68b28c34fa86895baa8d7f48307382e6c75 (patch) | |
tree | c3c31ad8c5d907c9aecc92ee349b2e3ff4c46ac0 /manifest_xml.py | |
parent | adaa1d8734b9759c6e5fcb89398f34659aec49da (diff) | |
download | git-repo-87cce68b28c34fa86895baa8d7f48307382e6c75.tar.gz |
Move local-manifest check to manifest_xml.py
This removes the need for git_superproject to include manifest_xml, and
puts the logic for local_manifest detection in one place.
Change-Id: I4d33ded0542ceea4606a1ea24304f678de20c59e
Reviewed-on: https://gerrit-review.googlesource.com/c/git-repo/+/330499
Tested-by: LaMont Jones <lamontjones@google.com>
Reviewed-by: Raman Tenneti <rtenneti@google.com>
Diffstat (limited to 'manifest_xml.py')
-rw-r--r-- | manifest_xml.py | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/manifest_xml.py b/manifest_xml.py index daf85d30..7c5906da 100644 --- a/manifest_xml.py +++ b/manifest_xml.py | |||
@@ -650,6 +650,12 @@ https://gerrit.googlesource.com/git-repo/+/HEAD/docs/manifest-format.md | |||
650 | def HasLocalManifests(self): | 650 | def HasLocalManifests(self): |
651 | return self._load_local_manifests and self.local_manifests | 651 | return self._load_local_manifests and self.local_manifests |
652 | 652 | ||
653 | def IsFromLocalManifest(self, project): | ||
654 | """Is the project from a local manifest? | ||
655 | """ | ||
656 | return any(x.startswith(LOCAL_MANIFEST_GROUP_PREFIX) | ||
657 | for x in project.groups) | ||
658 | |||
653 | @property | 659 | @property |
654 | def IsMirror(self): | 660 | def IsMirror(self): |
655 | return self.manifestProject.config.GetBoolean('repo.mirror') | 661 | return self.manifestProject.config.GetBoolean('repo.mirror') |