Documentation ¶
Index ¶
- type Repo
- func (rr *Repo) GetDefaultBranch(ctx context.Context) (git.ReferenceName, error)
- func (rr *Repo) HasBranches(ctx context.Context) (bool, error)
- func (rr *Repo) HeadReference(ctx context.Context) (git.ReferenceName, error)
- func (rr *Repo) ObjectHash(ctx context.Context) (git.ObjectHash, error)
- func (rr *Repo) ResolveRevision(ctx context.Context, revision git.Revision) (git.ObjectID, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Repo ¶
type Repo struct { *gitalypb.Repository // contains filtered or unexported fields }
Repo represents a Git repository on a different Gitaly storage
func (*Repo) GetDefaultBranch ¶
GetDefaultBranch returns the default branch for the remote repository. It does so by invoking `FindDefaultBranchName()`, which itself is a wrapper around `localrepo.GetDefaultBranch()`. Semantics of this function thus match the localrepo semantics.
func (*Repo) HasBranches ¶
HasBranches will dial to the remote repository and check whether the repository has any branches.
func (*Repo) HeadReference ¶ added in v16.2.0
HeadReference returns the reference that HEAD points to for the remote repository.
func (*Repo) ObjectHash ¶
ObjectHash detects the object hash used by this particular repository.
Click to show internal directories.
Click to hide internal directories.