0
0
Fork 0
mirror of https://github.com/go-gitea/gitea synced 2024-10-29 18:29:14 +01:00
gitea/modules/gitrepo/walk_nogogit.go

18 lines
429 B
Go
Raw Normal View History

// Copyright 2024 The Gitea Authors. All rights reserved.
// SPDX-License-Identifier: MIT
//go:build !gogit
package gitrepo
import (
"context"
"code.gitea.io/gitea/modules/git"
)
// WalkReferences walks all the references from the repository
func WalkReferences(ctx context.Context, repo Repository, walkfn func(sha1, refname string) error) (int, error) {
return git.WalkShowRef(ctx, repoPath(repo), nil, 0, 0, walkfn)
}