bitbake: fetch2/git: Allow other namespaces than refs/heads to be searched.
This makes it possble to fetch Gerrit review references which are normally stored under refs/changes. Please disregard previous patch with the same topic. (Bitbake rev: 268e9c0c6830e8e621c418f20c2ca12dc840e48b) Signed-off-by: Fredrik Svensson <fredrik.svensson@axis.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
parent
5fa2ce0773
commit
bc6330cb7f
|
@ -339,7 +339,10 @@ class Git(FetchMethod):
|
|||
"""
|
||||
Compute the HEAD revision for the url
|
||||
"""
|
||||
search = "refs/heads/%s refs/tags/%s^{}" % (ud.unresolvedrev[name], ud.unresolvedrev[name])
|
||||
if ud.unresolvedrev[name][:5] == "refs/":
|
||||
search = "%s %s^{}" % (ud.unresolvedrev[name], ud.unresolvedrev[name])
|
||||
else:
|
||||
search = "refs/heads/%s refs/tags/%s^{}" % (ud.unresolvedrev[name], ud.unresolvedrev[name])
|
||||
output = self._lsremote(ud, d, search)
|
||||
return output.split()[0]
|
||||
|
||||
|
|
Loading…
Reference in New Issue