Documentation
¶
Index ¶
- func CheckRepoState(path string) (repoState report.RepoState, warnings []string)
- func GetGitRepoStatesConcurrent(paths []string, maxWorkers int) ([]report.RepoState, []string)
- func GetRepoBranch(path string) (branchName string, err error)
- func GetRepoName(repoPath string) (string, error)
- func GetUncommitedFiles(path string) (changes []string, err error)
- func GetUpstreamStatus(path string) (ahead int, behind int, err error)
- func GitFetch(path string) (string, error)
- func GitPull(path string) (string, error)
- func GitPush(path string) (string, error)
- func RunGitCommand(dir string, args ...string) (string, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CheckRepoState ¶
CheckRepoState inspects the Git repository at path and returns its RepoState along with any non-fatal warnings encountered while collecting information.
func GetGitRepoStatesConcurrent ¶
GetGitRepoStatesConcurrent gathers RepoState for each path concurrently using up to maxWorkers goroutines. It returns states sorted by Path and any warnings.
func GetRepoBranch ¶
GetRepoBranch returns the current branch name for the Git repository at path.
func GetRepoName ¶
GetRepoName tries to extract the repository name from its remote URL, falling back to the first remote name or the local folder name if needed.
func GetUncommitedFiles ¶
GetUncommitedFiles returns the list of uncommitted files (status porcelain) for the Git repository at path.
func GetUpstreamStatus ¶
GetUpstreamStatus returns the ahead/behind counts relative to the upstream tracking branch for the repository at path.
Types ¶
This section is empty.