summaryrefslogtreecommitdiffstats
path: root/error.py
diff options
context:
space:
mode:
authorColin Cross <ccross@android.com>2012-03-28 20:15:45 -0700
committerShawn Pearce <sop@google.com>2012-04-13 09:46:00 -0700
commit5acde75e5d70b323197ffb2c9d4fdea3612098f5 (patch)
treee995a64614ce7406633ae6e99c2a0e6f86872e09 /error.py
parentd67872d2f47b2f09a0e2aa4adfd62e6f69154c9b (diff)
downloadgit-repo-5acde75e5d70b323197ffb2c9d4fdea3612098f5.tar.gz
Add manifest groupsv1.8.2
Allows specifying a list of groups with a -g argument to repo init. The groups act on a group= attribute specified on projects in the manifest. All projects are implicitly labelled with "default" unless they are explicitly labelled "-default". Prefixing a group with "-" removes matching projects from the list of projects to sync. If any non-inverted manifest groups are specified, the default label is ignored. Change-Id: I3a0dd7a93a8a1756205de1d03eee8c00906af0e5 Reviewed-on: https://gerrit-review.googlesource.com/34570 Reviewed-by: Shawn Pearce <sop@google.com> Tested-by: Shawn Pearce <sop@google.com>
Diffstat (limited to 'error.py')
-rw-r--r--error.py12
1 files changed, 12 insertions, 0 deletions
diff --git a/error.py b/error.py
index 812585cd..78c5c0e0 100644
--- a/error.py
+++ b/error.py
@@ -77,6 +77,18 @@ class NoSuchProjectError(Exception):
77 return 'in current directory' 77 return 'in current directory'
78 return self.name 78 return self.name
79 79
80
81class InvalidProjectGroupsError(Exception):
82 """A specified project is not suitable for the specified groups
83 """
84 def __init__(self, name=None):
85 self.name = name
86
87 def __str__(self):
88 if self.Name is None:
89 return 'in current directory'
90 return self.name
91
80class RepoChangedException(Exception): 92class RepoChangedException(Exception):
81 """Thrown if 'repo sync' results in repo updating its internal 93 """Thrown if 'repo sync' results in repo updating its internal
82 repo or manifest repositories. In this special case we must 94 repo or manifest repositories. In this special case we must