Using the repo tool on other projects

626 views
Skip to first unread message

Bradley

unread,
Apr 15, 2010, 11:52:14 AM4/15/10
to Repo and Gerrit Discussion
Has the repo tool been used on other projects? If so, what
configuration issues have you run into? Specifically, it appears that
repo expects a special build.git reposistory. What is this repository
supposed to contain?
Thanks,
Brad

Shawn Pearce

unread,
Apr 15, 2010, 8:53:04 PM4/15/10
to Bradley, Repo and Gerrit Discussion
Bradley <bradley.l...@gmail.com> wrote:
> Has the repo tool been used on other projects? If so, what
> configuration issues have you run into?

Its been tried on a few others, but nothing really notable that I
can point you to and say "they also use repo".

> Specifically, it appears that
> repo expects a special build.git reposistory.

That shouldn't be the case. I'm pretty certain it doesn't need a
build.git repository. What error are you running into that makes
you believe this is necessary?

--
To unsubscribe, email repo-discuss...@googlegroups.com
More info at http://groups.google.com/group/repo-discuss?hl=en

Bradley

unread,
Apr 16, 2010, 10:57:50 AM4/16/10
to Repo and Gerrit Discussion
I am able to init a repo:
repo init -u ssh://mymachine/home/git/git.repo/myManifest.git/ --repo-
url http://android.git.kernel.org/tools/repo.git

but when I attempt to sync I get this message:
$ repo sync

Initializing project build ...
fatal: '/home/git/git.repo/build.git' does not appear to be a git
repository
fatal: The remote end hung up unexpectedly
error: Cannot fetch build
$

I don't have a reference to a build.git in my manifest.
Thanks,
Brad

On Apr 15, 7:53 pm, Shawn Pearce <s...@google.com> wrote:

Shawn Pearce

unread,
Apr 16, 2010, 11:06:01 AM4/16/10
to Bradley, Repo and Gerrit Discussion
On Fri, Apr 16, 2010 at 07:57, Bradley <bradley.l...@gmail.com> wrote:
> I am able to init a repo:
> repo init -u ssh://mymachine/home/git/git.repo/myManifest.git/ --repo-
> url http://android.git.kernel.org/tools/repo.git
>
> but when I attempt to sync I get this message:
> $ repo sync
>
> Initializing project build ...
> fatal: '/home/git/git.repo/build.git' does not appear to be a git
> repository
> fatal: The remote end hung up unexpectedly
> error: Cannot fetch build
> $
>
> I don't have a reference to a build.git in my manifest.

You must though. Check .repo/manifests/default.xml. Whatever is in
there is what repo is using. Its possible you are using a stale
manifest, and need to commit and push the manifest you need to your
ssh://mymachine/home/git/git.repo/myManifest.git/ repository.

You can examine the source code if you look under .repo/repo. E.g.
`cd .repo/repo ; git grep build` produces no results that indicate
repo is hardcoded to need a 'build.git' repository. So it must be
coming from your manifest.

Bradley

unread,
Apr 16, 2010, 2:13:02 PM4/16/10
to Repo and Gerrit Discussion
You're right. There is a reference to a build.git in the config
file, .repo/projects/build/build.git/config

[core]
repositoryformatversion = 0
filemode = true
[user]
email = br...@mail.com
[remote "myRemote"]
url = ssh://myMachine/home/git/git.repo/build.git
projectname = build
fetch = +refs/heads/*:refs/remotes/myRemote/*

It might be from the repo manifest
Looking at the file, .repo/repo/docs/manifest-format.txt, in the
"Element project" section, the suffix, ".git" is appended to the
repository names defined in the manifest..
Thanks,
Brad

Bradley

unread,
May 6, 2010, 12:18:16 PM5/6/10
to Repo and Gerrit Discussion
in order to help others, I thought I would report my solution.
1) Remote repo projects in the manifest must be bare and have a ".git"
suffix. If you created the remote repo with "git clone --bare" it
will have ".git" appended to the repo name already. If you created it
using "git --bare init" then you created the directory and so should
have explicitly named it with the ".git" suffix.
2) if you are accessing the android repo project repository through a
firewall, the git protocol will probably not get through. You can try
the http protocol. You'll can specify the repo url explicitly with
this argument to repo "--repo-url http://android.git.kernel.org/tools/repo.git"
Or, edit the "REPO_URL" in your local copy of the repo script. The
other solution to this problem is to clone the repo project locally,
"git clone --bare http://android.git.kernel.org/tools/repo.git"
Then, either pass the local repo url explicitly as a repo arg with --
repo-url or edit the local copy of the repo script to refer to your
local copy.
Reply all
Reply to author
Forward
0 new messages