diff --git a/cmd/zoekt-indexserver/main.go b/cmd/zoekt-indexserver/main.go index 05140ea75..2107503a6 100644 --- a/cmd/zoekt-indexserver/main.go +++ b/cmd/zoekt-indexserver/main.go @@ -129,7 +129,7 @@ func periodicFetch(repoDir, indexDir string, opts *Options, pendingRepos chan<- // fetchGitRepo runs git-fetch, and returns true if there was an // update. func fetchGitRepo(dir string) bool { - cmd := exec.Command("git", "--git-dir", dir, "fetch", "origin") + cmd := exec.Command("git", "--git-dir", dir, "fetch", "origin", "--prune") output, err := cmd.CombinedOutput() if err != nil {