Documentation ¶
Index ¶
- Variables
- func NewAzureClient() *azureClient
- func NewGitClient(preserveGitDir bool) *gitClient
- type Service
- func (service *Service) CloneRepository(destination, repositoryURL, referenceName, username, password string) error
- func (service *Service) LatestCommitID(repositoryURL, referenceName, username, password string) (string, error)
- func (service *Service) ListFiles(repositoryURL, referenceName, username, password string, hardRefresh bool, ...) ([]string, error)
- func (service *Service) ListRefs(repositoryURL, username, password string, hardRefresh bool) ([]string, error)
Constants ¶
This section is empty.
Variables ¶
View Source
var ( REPOSITORY_CACHE_SIZE = 4 REPOSITORY_CACHE_TTL = 5 * time.Minute )
Functions ¶
func NewAzureClient ¶
func NewAzureClient() *azureClient
func NewGitClient ¶
func NewGitClient(preserveGitDir bool) *gitClient
Types ¶
type Service ¶
type Service struct {
// contains filtered or unexported fields
}
Service represents a service for managing Git.
func NewService ¶
NewService initializes a new service.
func (*Service) CloneRepository ¶
func (service *Service) CloneRepository(destination, repositoryURL, referenceName, username, password string) error
CloneRepository clones a git repository using the specified URL in the specified destination folder.
func (*Service) LatestCommitID ¶
func (service *Service) LatestCommitID(repositoryURL, referenceName, username, password string) (string, error)
LatestCommitID returns SHA1 of the latest commit of the specified reference
func (*Service) ListFiles ¶
func (service *Service) ListFiles(repositoryURL, referenceName, username, password string, hardRefresh bool, includedExts []string) ([]string, error)
ListFiles will list all the files of the target repository with specific extensions. If extension is not provided, it will list all the files under the target repository
Click to show internal directories.
Click to hide internal directories.