Enable remotes to define their own revision
Some projects use multiple remotes.
In some cases these remotes have different naming conventions.
Add an option to define a revision in the remote configuration.
The `project` revision takes precedence over `remote` and `default`.
The `remote` revision takes precedence over `default`.
The `default` revision acts as a fall back as it originally did.
Change-Id: I2b376160d45d48b0bab840c02a3eef1a1e32cf6d
diff --git a/project.py b/project.py
index 127176e..db380a0 100644
--- a/project.py
+++ b/project.py
@@ -259,10 +259,12 @@
def __init__(self,
name,
url = None,
- review = None):
+ review = None,
+ revision = None):
self.name = name
self.url = url
self.review = review
+ self.revision = revision
class RepoHook(object):
"""A RepoHook contains information about a script to run as a hook.
@@ -1657,7 +1659,8 @@
remote = RemoteSpec(self.remote.name,
url = url,
- review = self.remote.review)
+ review = self.remote.review,
+ revision = self.remote.revision)
subproject = Project(manifest = self.manifest,
name = name,
remote = remote,