| Issue 538: | create-project creates extra repo directory when used to add an existing repo | |
| 2 people starred this issue and may be notified of changes. | Back to list |
Scenario: * gerrit.basePath=/repo/git * There's an existing bare repo called 'xyz' (/repo/git/xyz) I want to add this repo to gerrit's project list so I do "ssh gerrit-host gerrit create-project --name xyz". The command completes successfully and the project is added to gerrit's list. However, I notice as a side effect that a /repo/git/xyz.git directory has been created. It seems to be a completely fresh repo. However, all change submissions work against the real repo (/repo/git/xyz) as desired.
Apr 25, 2010
Does that mean one cannot add an existing repo as a gerrit project? Or does this mean that create-project will do enough to add the repo to the project just, but won't attempt to actually create the repo if it already exists?
Apr 27, 2010
I'd like to know the answer to dancysoft's question, too.
Apr 27, 2010
Right now, create-project will fail out if the repository already exists under basePath, even if it doesn't exist in the database. So there is no way to register a repository that already exists under basePath. However, you can run init to rescan and import all projects into the database. It may make sense to change create-project's behavior to register an existing repository. But I'd rather spend my time on getting rid of that database altogether and rely solely on the Git storage. Then registration is unnecessary and the server just picks it up automatically if its in the proper location. So if someone else sends a change to create-project to make it register an existing directory, I'll merge it. But I'm not going to write that change myself because I'd like it to be obsolete before the end of May. Chasing these little bugs that I know are just going to go away due to other features just delays them going away.
Mar 27, 2012
(No comment was entered for this change.)
Status:
Released
|
|
| ► Sign in to add a comment |
Labels: FixedIn-2.1.2.3
Blockedon: 537