google / zoekt

Fast trigram based code search

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Github repos no longer get updated

dziemba opened this issue · comments

We're using zoekt-indexserver with a GithubOrg mirror_config. Everything else (especially branches, origins etc.) is not changed from the default values.

Commit 47ff303 changed how git fetching is configured.

Repos that are cloned from github get indexed correctly initially, but then the git fetch calls do not fetch the required refs anymore.

Previous behavior:

$ git clone --bare https://github.com/dziemba/dotfiles.git \
  --config "remote.origin.fetch=+refs/heads/*:refs/heads/*"
[...]
$ cd dotfiles.git
$ git fetch -v
From https://github.com/dziemba/dotfiles
 = [up to date]      master     -> master

Current behavior:

$ git clone --bare https://github.com/dziemba/dotfiles.git
[...]
$ cd dotfiles.git
$ git fetch -v
From https://github.com/dziemba/dotfiles
 * branch            HEAD       -> FETCH_HEAD

The behavior is the same with git 2.20.0 and 2.24.0.

I'm not a git expert, please let me know if you need more information.

this sounds believable. We probably have to add git-config

"remote.origin.fetch=+refs/heads/:refs/heads/"

somewhere as a step after cloning.

Thank you for the fix!

can you confirm that it works as expected?

Yes, it works fine 👍