[uploadpack]
allowTipSHA1InWant = true
allowReachableSHA1InWant = true
Hello,
I've nearly the same problem. Our gerrit projects are bare repositories. So, there doens't exist a ".git" directory, thus, I wonder if the "config" or ".gitconfig" are the files that must be modified.
I did try modifying them both, but git fetch silently fails.
I have been working on this shallow sync .we usually to repo init from gerit project and repo sync to get all the projects content and I have updated the manifiest files in manifest repo with clone-depth=1 and when I try to do the repo sync I am getting the error: Server does not allow request for unadvertised object ,I have updated the gerit config with below entries .Do I need to make these changes in every gerit project .git/config file to get rid of this issue ? any help on this would be greatGeritconfig changes :[uploadpack]allowTipSha1InWant = trueallowReachableSHA1InWant = trueallowAnySHA1InWant = true
I tried setting those in in my $HOME/.gitconfig but it didn't work ,problem is I am an end user just trying to do the repo init and repo sync for build purpose ,Our project is combination of different gerit projects from different clients ,my hunch is that I may need to update these configuration in every project repo git configuration i.e .repo/projects/foo/bar/foo.git .and one more thing when I make these configuration changes for every project does it still work for existing commit hash ? or only for new commits pushed after these configuration changes ??
On Thursday, July 26, 2018 at 7:35:47 PM UTC+2, Gert van Dijk wrote:I tried setting those in in my $HOME/.gitconfig but it didn't work ,problem is I am an end user just trying to do the repo init and repo sync for build purpose ,Our project is combination of different gerit projects from different clients ,my hunch is that I may need to update these configuration in every project repo git configuration i.e .repo/projects/foo/bar/foo.git .and one more thing when I make these configuration changes for every project does it still work for existing commit hash ? or only for new commits pushed after these configuration changes ??On Thursday, 26 July 2018 14:40:15 UTC+2, sunilkgb wrote:I have been working on this shallow sync .we usually to repo init from gerit project and repo sync to get all the projects content and I have updated the manifiest files in manifest repo with clone-depth=1 and when I try to do the repo sync I am getting the error: Server does not allow request for unadvertised object ,I have updated the gerit config with below entries .Do I need to make these changes in every gerit project .git/config file to get rid of this issue ? any help on this would be greatGeritconfig changes :[uploadpack]allowTipSha1InWant = trueallowReachableSHA1InWant = trueallowAnySHA1InWant = trueI believe it's a git configuration, not a Gerrit configuration that should be used. You may be successful in setting it globally for all projects using a global gitconfig file where JGit (as embedded in Gerrit) will pick it up. As the same user as your Gerrit server is running, perform:git config --global uploadpack.allowTipSha1InWant truegit config --global uploadpack.allowReachableSHA1InWant truegit config --global uploadpack.allowAnySHA1InWant true(Or just edit the $HOME/.gitconfig yourself.)