package
0.0.0-20240128054700-7954b2e94b5f
Repository: https://github.com/shakefu/commonrepo.git
Documentation: pkg.go.dev

# Functions

ApplyInsteadOf returns the remote URL with the instead of rules applied.
DefaultRef returns a ref pointing at the default HEAD for the repository, since not all repositories will use "main", this will determine it for us.
DetectGitPath returns the repository root of the specified path, if there is one.
FindInsteadOfMatch returns the longest matching URL rule This is borrowed directly from go-git: https://github.com/go-git/go-git/blob/master/config/url.go#L59.
FindLocalRepoPath returns the full path to the repository containing the current working directory.
FindRef returns a ref from the given refname, or falls back to the default branch for the repository.
GetRefs returns a map of all the available refs This is borrowed from: https://github.com/go-git/go-git/issues/249#issuecomment-772354474.
LoadGitConfig returns the system and global git configs merged together.
LocalBranch returns the current ref for this repository.
RemoteDefaultBranch returns the current ref for this repository.