mirror of
https://git.codelinaro.org/clo/tools/repo.git
synced 2025-09-12 23:16:18 +08:00
Add <remote project-name="..."> attribute within projects
By setting a project-name on a remote nested within a project forks of a project like the Linux kernel can be easily handled by fetching all relevant forks into the same client side project under different remote names. Developers can create branches off different remotes using `git checkout --track -b $myname $remote/$branch` and later `repo upload` automatically redirects to the proper fork project in the code review server. Signed-off-by: Shawn O. Pearce <sop@google.com>
This commit is contained in:
@ -904,7 +904,9 @@ class Project(object):
|
||||
remote = self.GetRemote(r.name)
|
||||
remote.url = r.fetchUrl
|
||||
remote.review = r.reviewUrl
|
||||
if remote.projectname is None:
|
||||
if r.projectName:
|
||||
remote.projectname = r.projectName
|
||||
elif remote.projectname is None:
|
||||
remote.projectname = self.name
|
||||
remote.ResetFetch()
|
||||
remote.Save()
|
||||
|
Reference in New Issue
Block a user