Fast implementation of Git in pure Go codeberg.org/lindenii/furgit
git go
6
fork

Configure Feed

Select the types of activity you want to include in your feed.

reachability, repository: MT-Safe reachability

Runxi Yu e1799381 e75510d1

+15 -3
+1 -1
reachability/reachability.go
··· 8 8 9 9 // Reachability provides graph traversal over objects in one object store. 10 10 // 11 - // Labels: MT-Unsafe. 11 + // Labels: MT-Safe. 12 12 type Reachability struct { 13 13 store objectstore.ReadingStore 14 14 graph *commitgraphread.Reader
+11
repository/reachability.go
··· 1 + package repository 2 + 3 + import "codeberg.org/lindenii/furgit/reachability" 4 + 5 + // Reachability returns graph traversal helpers backed by the repository's 6 + // object store and optional commit-graph. 7 + // 8 + // Labels: Life-Parent, Close-No. 9 + func (repo *Repository) Reachability() *reachability.Reachability { 10 + return reachability.New(repo.objects, repo.commitGraph) 11 + }
+3 -2
repository/repository.go
··· 21 21 // a bare repository root or a non-bare ".git" directory. 22 22 // 23 23 // Accessors such as [Repository.Objects], [Repository.CommitGraph], 24 - // [Repository.CommitQueries], [Repository.Refs], [Repository.Fetcher], 25 - // and [Repository.LooseStoreForWriting] return repository-backed views. 24 + // [Repository.CommitQueries], [Repository.Reachability], [Repository.Refs], 25 + // [Repository.Fetcher], and [Repository.LooseStoreForWriting] return 26 + // repository-backed views. 26 27 // 27 28 // Labels: MT-Safe, Close-Caller. 28 29 type Repository struct {