summaryrefslogtreecommitdiffstats
path: root/manifest_xml.py
diff options
context:
space:
mode:
authorLaMont Jones <lamontjones@google.com>2022-04-06 17:10:21 +0000
committerLaMont Jones <lamontjones@google.com>2022-04-06 21:04:46 +0000
commit55ee304304a0d83bfa23984c45e46eebdd184124 (patch)
tree5eaaf4b84b4c8caf20cb1051b753c998d0eaa159 /manifest_xml.py
parent409407a73172b31efcee947db66ae099515eeaab (diff)
downloadgit-repo-55ee304304a0d83bfa23984c45e46eebdd184124.tar.gz
Fix sub manifest handling
Also fixes some typos Change-Id: Id2ba5834ba3a74ed3f29c36d2c0030737dc63e35 Reviewed-on: https://gerrit-review.googlesource.com/c/git-repo/+/334579 Tested-by: LaMont Jones <lamontjones@google.com> Reviewed-by: Mike Frysinger <vapier@google.com>
Diffstat (limited to 'manifest_xml.py')
-rw-r--r--manifest_xml.py9
1 files changed, 5 insertions, 4 deletions
diff --git a/manifest_xml.py b/manifest_xml.py
index 022cad20..02f09db9 100644
--- a/manifest_xml.py
+++ b/manifest_xml.py
@@ -243,12 +243,13 @@ class _XmlSubmanifest:
243 manifestFile = parent.SubmanifestInfoDir( 243 manifestFile = parent.SubmanifestInfoDir(
244 os.path.join(parent.path_prefix, self.relpath), 244 os.path.join(parent.path_prefix, self.relpath),
245 os.path.join('manifests', manifestName or 'default.xml')) 245 os.path.join('manifests', manifestName or 'default.xml'))
246 linkFile = parent.SubmanifestInfoDir(
247 os.path.join(parent.path_prefix, self.relpath), MANIFEST_FILE_NAME)
246 rc = self.repo_client = RepoClient( 248 rc = self.repo_client = RepoClient(
247 parent.repodir, manifestFile, parent_groups=','.join(groups) or '', 249 parent.repodir, linkFile, parent_groups=','.join(groups) or '',
248 submanifest_path=self.relpath, outer_client=outer_client) 250 submanifest_path=self.relpath, outer_client=outer_client)
249 251
250 self.present = os.path.exists(os.path.join(self.repo_client.subdir, 252 self.present = os.path.exists(manifestFile)
251 MANIFEST_FILE_NAME))
252 253
253 def __eq__(self, other): 254 def __eq__(self, other):
254 if not isinstance(other, _XmlSubmanifest): 255 if not isinstance(other, _XmlSubmanifest):
@@ -1051,7 +1052,7 @@ https://gerrit.googlesource.com/git-repo/+/HEAD/docs/manifest-format.md
1051 tree.present = present 1052 tree.present = present
1052 elif not os.path.exists(self.subdir): 1053 elif not os.path.exists(self.subdir):
1053 tree.present = False 1054 tree.present = False
1054 if tree.present: 1055 if present and tree.present:
1055 tree.repo_client._Load(initial_client=initial_client, 1056 tree.repo_client._Load(initial_client=initial_client,
1056 submanifest_depth=submanifest_depth + 1) 1057 submanifest_depth=submanifest_depth + 1)
1057 1058