summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--docs/manifest-format.txt6
-rw-r--r--manifest_xml.py5
2 files changed, 8 insertions, 3 deletions
diff --git a/docs/manifest-format.txt b/docs/manifest-format.txt
index 9f4585b8..a827f556 100644
--- a/docs/manifest-format.txt
+++ b/docs/manifest-format.txt
@@ -171,7 +171,11 @@ the default element is used.
171 171
172Attribute `groups`: List of groups to which this project belongs, 172Attribute `groups`: List of groups to which this project belongs,
173whitespace or comma separated. All projects belong to the group 173whitespace or comma separated. All projects belong to the group
174"default". 174"default", and each project automatically belongs to a group of
175it's name:`name` and path:`path`. E.g. for
176<project name="monkeys" path="barrel-of"/>, that project
177definition is implicitly in the following manifest groups:
178default, name:monkeys, and path:barrel-of.
175 179
176Element annotation 180Element annotation
177------------------ 181------------------
diff --git a/manifest_xml.py b/manifest_xml.py
index a46cf24e..86899f63 100644
--- a/manifest_xml.py
+++ b/manifest_xml.py
@@ -566,8 +566,9 @@ class XmlManifest(object):
566 if node.hasAttribute('groups'): 566 if node.hasAttribute('groups'):
567 groups = node.getAttribute('groups') 567 groups = node.getAttribute('groups')
568 groups = [x for x in re.split('[,\s]+', groups) if x] 568 groups = [x for x in re.split('[,\s]+', groups) if x]
569 if 'default' not in groups: 569
570 groups.append('default') 570 default_groups = ['default', 'name:%s' % name, 'path:%s' % path]
571 groups.extend(set(default_groups).difference(groups))
571 572
572 if self.IsMirror: 573 if self.IsMirror:
573 relpath = None 574 relpath = None