Documentation
¶
Overview ¶
Package repo provides functions for accessing VCS information.
Index ¶
Constants ¶
View Source
const ( Git = "git" Hg = "mercurial" SVN = "subversion" Bzr = "bazaar" CVS = "cvs" )
Repository types.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Repo ¶
type Repo interface {
// FetchCommits populates Commits attribute with all commits of a repository.
FetchCommits() error
// GetRepository returns a repository structure from a repo.
GetRepository() *model.Repository
// GetName returns the name of a repo.
GetName() string
// GetVCS returns the VCS typoe of a repo.
GetVCS() string
// GetCloneURL returns the clone URL of a repo.
GetCloneURL() string
// GetClonePath returns the clone path of a repo.
GetClonePath() string
// GetDefaultBranch returns the default branch of a repo.
GetDefaultBranch() string
// GetCommits returns the list of commits of a repo.
GetCommits() []model.Commit
// Cleanup needs to be called when done using the repository. It performs
// some housekeeping if necessary.
Cleanup() error
}
Repo interface defines what needs to be implemented to construct a Repo object.
Click to show internal directories.
Click to hide internal directories.