summaryrefslogtreecommitdiffstats
path: root/manifest_xml.py
diff options
context:
space:
mode:
Diffstat (limited to 'manifest_xml.py')
-rw-r--r--manifest_xml.py11
1 files changed, 11 insertions, 0 deletions
diff --git a/manifest_xml.py b/manifest_xml.py
index 92ef7859..4eef748f 100644
--- a/manifest_xml.py
+++ b/manifest_xml.py
@@ -665,6 +665,16 @@ class XmlManifest(object):
665 else: 665 else:
666 sync_s = sync_s.lower() in ("yes", "true", "1") 666 sync_s = sync_s.lower() in ("yes", "true", "1")
667 667
668 clone_depth = node.getAttribute('clone-depth')
669 if clone_depth:
670 try:
671 clone_depth = int(clone_depth)
672 if clone_depth <= 0:
673 raise ValueError()
674 except ValueError:
675 raise ManifestParseError('invalid clone-depth %s in %s' %
676 (clone_depth, self.manifestFile))
677
668 upstream = node.getAttribute('upstream') 678 upstream = node.getAttribute('upstream')
669 679
670 groups = '' 680 groups = ''
@@ -692,6 +702,7 @@ class XmlManifest(object):
692 groups = groups, 702 groups = groups,
693 sync_c = sync_c, 703 sync_c = sync_c,
694 sync_s = sync_s, 704 sync_s = sync_s,
705 clone_depth = clone_depth,
695 upstream = upstream, 706 upstream = upstream,
696 parent = parent) 707 parent = parent)
697 708