diff options
author | Shawn O. Pearce <sop@google.com> | 2009-07-03 15:29:02 -0700 |
---|---|---|
committer | Shawn O. Pearce <sop@google.com> | 2009-07-03 20:03:38 -0700 |
commit | cc6c79643e1cafad565424caabe581e7b548bf6f (patch) | |
tree | 29fe305852e0488f54548e1d2a9d3e39f8d39f85 /manifest_xml.py | |
parent | 2095179beec754d2d5bfe175215e736b7ff838e9 (diff) | |
download | git-repo-cc6c79643e1cafad565424caabe581e7b548bf6f.tar.gz |
Make refs/remotes/m management the manifest object's responsibility
I plan to have the new submodule manifest format use a different
layout for the m refs than the XML manifest format has used in
the past. Thus we need to move the behavior management into the
manifest object, and out of the project, so we can change it.
Signed-off-by: Shawn O. Pearce <sop@google.com>
Diffstat (limited to 'manifest_xml.py')
-rw-r--r-- | manifest_xml.py | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/manifest_xml.py b/manifest_xml.py index 97df75bd..66cdf3e3 100644 --- a/manifest_xml.py +++ b/manifest_xml.py | |||
@@ -29,6 +29,7 @@ from error import ManifestParseError | |||
29 | 29 | ||
30 | MANIFEST_FILE_NAME = 'manifest.xml' | 30 | MANIFEST_FILE_NAME = 'manifest.xml' |
31 | LOCAL_MANIFEST_NAME = 'local_manifest.xml' | 31 | LOCAL_MANIFEST_NAME = 'local_manifest.xml' |
32 | R_M = 'refs/remotes/m/' | ||
32 | 33 | ||
33 | class _Default(object): | 34 | class _Default(object): |
34 | """Project defaults within the manifest.""" | 35 | """Project defaults within the manifest.""" |
@@ -168,6 +169,10 @@ class XmlManifest(Manifest): | |||
168 | self._Load() | 169 | self._Load() |
169 | return self._default | 170 | return self._default |
170 | 171 | ||
172 | def SetMRefs(self, project): | ||
173 | if self.branch: | ||
174 | project._InitAnyMRef(R_M + self.branch) | ||
175 | |||
171 | def _Unload(self): | 176 | def _Unload(self): |
172 | self._loaded = False | 177 | self._loaded = False |
173 | self._projects = {} | 178 | self._projects = {} |