Documentation ¶
Index ¶
- Constants
- Variables
- type AWSCodeCommitClient
- type AWSCodeCommitProvider
- func (p *AWSCodeCommitProvider) GetBranches(ctx context.Context, repo *Repository) ([]*Repository, error)
- func (p *AWSCodeCommitProvider) ListRepos(ctx context.Context, cloneProtocol string) ([]*Repository, error)
- func (p *AWSCodeCommitProvider) RepoHasPath(ctx context.Context, repo *Repository, path string) (bool, error)
- type AWSTaggingClient
- type AzureDevOpsClientFactory
- type AzureDevOpsProvider
- func (g *AzureDevOpsProvider) GetBranches(ctx context.Context, repo *Repository) ([]*Repository, error)
- func (g *AzureDevOpsProvider) ListRepos(ctx context.Context, cloneProtocol string) ([]*Repository, error)
- func (g *AzureDevOpsProvider) RepoHasPath(ctx context.Context, repo *Repository, path string) (bool, error)
- type BitBucketCloudProvider
- func (g *BitBucketCloudProvider) GetBranches(ctx context.Context, repo *Repository) ([]*Repository, error)
- func (g *BitBucketCloudProvider) ListRepos(ctx context.Context, cloneProtocol string) ([]*Repository, error)
- func (g *BitBucketCloudProvider) RepoHasPath(ctx context.Context, repo *Repository, path string) (bool, error)
- type BitbucketServerProvider
- func (b *BitbucketServerProvider) GetBranches(_ context.Context, repo *Repository) ([]*Repository, error)
- func (b *BitbucketServerProvider) ListRepos(_ context.Context, cloneProtocol string) ([]*Repository, error)
- func (b *BitbucketServerProvider) RepoHasPath(_ context.Context, repo *Repository, path string) (bool, error)
- type ExtendedClient
- type Filter
- type FilterType
- type GiteaProvider
- type GithubProvider
- func (g *GithubProvider) GetBranches(ctx context.Context, repo *Repository) ([]*Repository, error)
- func (g *GithubProvider) ListRepos(ctx context.Context, cloneProtocol string) ([]*Repository, error)
- func (g *GithubProvider) RepoHasPath(ctx context.Context, repo *Repository, path string) (bool, error)
- type GitlabProvider
- func (g *GitlabProvider) GetBranches(ctx context.Context, repo *Repository) ([]*Repository, error)
- func (g *GitlabProvider) ListRepos(ctx context.Context, cloneProtocol string) ([]*Repository, error)
- func (g *GitlabProvider) RepoHasPath(_ context.Context, repo *Repository, path string) (bool, error)
- type MockProvider
- type Repository
- type SCMProviderService
Constants ¶
View Source
const AZURE_DEVOPS_DEFAULT_URL = "https://dev.azure.com"
Variables ¶
View Source
var AzureDevOpsErrorsTypeKeyValues = azureDevOpsErrorTypeKeyValuesType{
GitRepositoryNotFound: "GitRepositoryNotFoundException",
GitItemNotFound: "GitItemNotFoundException",
}
Functions ¶
This section is empty.
Types ¶
type AWSCodeCommitClient ¶ added in v2.8.0
type AWSCodeCommitClient interface { ListRepositoriesWithContext(aws.Context, *codecommit.ListRepositoriesInput, ...request.Option) (*codecommit.ListRepositoriesOutput, error) GetRepositoryWithContext(aws.Context, *codecommit.GetRepositoryInput, ...request.Option) (*codecommit.GetRepositoryOutput, error) ListBranchesWithContext(aws.Context, *codecommit.ListBranchesInput, ...request.Option) (*codecommit.ListBranchesOutput, error) GetFolderWithContext(aws.Context, *codecommit.GetFolderInput, ...request.Option) (*codecommit.GetFolderOutput, error) }
AWSCodeCommitClient is a lean facade to the codecommitiface.CodeCommitAPI it helps to reduce the mockery generated code.
type AWSCodeCommitProvider ¶ added in v2.8.0
type AWSCodeCommitProvider struct {
// contains filtered or unexported fields
}
func NewAWSCodeCommitProvider ¶ added in v2.8.0
func NewAWSCodeCommitProvider(ctx context.Context, tagFilters []*application.TagFilter, role string, region string, allBranches bool) (*AWSCodeCommitProvider, error)
func (*AWSCodeCommitProvider) GetBranches ¶ added in v2.8.0
func (p *AWSCodeCommitProvider) GetBranches(ctx context.Context, repo *Repository) ([]*Repository, error)
func (*AWSCodeCommitProvider) ListRepos ¶ added in v2.8.0
func (p *AWSCodeCommitProvider) ListRepos(ctx context.Context, cloneProtocol string) ([]*Repository, error)
func (*AWSCodeCommitProvider) RepoHasPath ¶ added in v2.8.0
func (p *AWSCodeCommitProvider) RepoHasPath(ctx context.Context, repo *Repository, path string) (bool, error)
type AWSTaggingClient ¶ added in v2.8.0
type AWSTaggingClient interface {
GetResourcesWithContext(aws.Context, *resourcegroupstaggingapi.GetResourcesInput, ...request.Option) (*resourcegroupstaggingapi.GetResourcesOutput, error)
}
AWSTaggingClient is a lean facade to the resourcegroupstaggingapiiface.ResourceGroupsTaggingAPIAPI it helps to reduce the mockery generated code.
type AzureDevOpsClientFactory ¶ added in v2.5.0
type AzureDevOpsProvider ¶ added in v2.5.0
type AzureDevOpsProvider struct {
// contains filtered or unexported fields
}
func NewAzureDevOpsProvider ¶ added in v2.5.0
func (*AzureDevOpsProvider) GetBranches ¶ added in v2.5.0
func (g *AzureDevOpsProvider) GetBranches(ctx context.Context, repo *Repository) ([]*Repository, error)
func (*AzureDevOpsProvider) ListRepos ¶ added in v2.5.0
func (g *AzureDevOpsProvider) ListRepos(ctx context.Context, cloneProtocol string) ([]*Repository, error)
func (*AzureDevOpsProvider) RepoHasPath ¶ added in v2.5.0
func (g *AzureDevOpsProvider) RepoHasPath(ctx context.Context, repo *Repository, path string) (bool, error)
type BitBucketCloudProvider ¶
type BitBucketCloudProvider struct {
// contains filtered or unexported fields
}
func (*BitBucketCloudProvider) GetBranches ¶
func (g *BitBucketCloudProvider) GetBranches(ctx context.Context, repo *Repository) ([]*Repository, error)
func (*BitBucketCloudProvider) ListRepos ¶
func (g *BitBucketCloudProvider) ListRepos(ctx context.Context, cloneProtocol string) ([]*Repository, error)
func (*BitBucketCloudProvider) RepoHasPath ¶
func (g *BitBucketCloudProvider) RepoHasPath(ctx context.Context, repo *Repository, path string) (bool, error)
type BitbucketServerProvider ¶
type BitbucketServerProvider struct {
// contains filtered or unexported fields
}
func (*BitbucketServerProvider) GetBranches ¶
func (b *BitbucketServerProvider) GetBranches(_ context.Context, repo *Repository) ([]*Repository, error)
func (*BitbucketServerProvider) ListRepos ¶
func (b *BitbucketServerProvider) ListRepos(_ context.Context, cloneProtocol string) ([]*Repository, error)
func (*BitbucketServerProvider) RepoHasPath ¶
func (b *BitbucketServerProvider) RepoHasPath(_ context.Context, repo *Repository, path string) (bool, error)
type ExtendedClient ¶
func (*ExtendedClient) GetContents ¶
func (c *ExtendedClient) GetContents(repo *Repository, path string) (bool, error)
type Filter ¶
type Filter struct { RepositoryMatch *regexp.Regexp PathsExist []string PathsDoNotExist []string LabelMatch *regexp.Regexp BranchMatch *regexp.Regexp FilterType FilterType }
A compiled version of SCMProviderGeneratorFilter for performance.
type FilterType ¶
type FilterType int64
A convenience type for indicating where to apply a filter
const ( FilterTypeUndefined FilterType = iota FilterTypeBranch FilterTypeRepo )
The enum of filter types
type GiteaProvider ¶
type GiteaProvider struct {
// contains filtered or unexported fields
}
func NewGiteaProvider ¶
func (*GiteaProvider) GetBranches ¶
func (g *GiteaProvider) GetBranches(ctx context.Context, repo *Repository) ([]*Repository, error)
func (*GiteaProvider) ListRepos ¶
func (g *GiteaProvider) ListRepos(ctx context.Context, cloneProtocol string) ([]*Repository, error)
func (*GiteaProvider) RepoHasPath ¶
func (g *GiteaProvider) RepoHasPath(ctx context.Context, repo *Repository, path string) (bool, error)
type GithubProvider ¶
type GithubProvider struct {
// contains filtered or unexported fields
}
func NewGithubAppProviderFor ¶ added in v2.5.0
func NewGithubAppProviderFor(g github_app_auth.Authentication, organization string, url string, allBranches bool) (*GithubProvider, error)
func NewGithubProvider ¶
func (*GithubProvider) GetBranches ¶
func (g *GithubProvider) GetBranches(ctx context.Context, repo *Repository) ([]*Repository, error)
func (*GithubProvider) ListRepos ¶
func (g *GithubProvider) ListRepos(ctx context.Context, cloneProtocol string) ([]*Repository, error)
func (*GithubProvider) RepoHasPath ¶
func (g *GithubProvider) RepoHasPath(ctx context.Context, repo *Repository, path string) (bool, error)
type GitlabProvider ¶
type GitlabProvider struct {
// contains filtered or unexported fields
}
func NewGitlabProvider ¶
func (*GitlabProvider) GetBranches ¶
func (g *GitlabProvider) GetBranches(ctx context.Context, repo *Repository) ([]*Repository, error)
func (*GitlabProvider) ListRepos ¶
func (g *GitlabProvider) ListRepos(ctx context.Context, cloneProtocol string) ([]*Repository, error)
func (*GitlabProvider) RepoHasPath ¶
func (g *GitlabProvider) RepoHasPath(_ context.Context, repo *Repository, path string) (bool, error)
type MockProvider ¶
type MockProvider struct {
Repos []*Repository
}
func (*MockProvider) GetBranches ¶
func (m *MockProvider) GetBranches(_ context.Context, repo *Repository) ([]*Repository, error)
func (*MockProvider) ListRepos ¶
func (m *MockProvider) ListRepos(_ context.Context, _ string) ([]*Repository, error)
func (*MockProvider) RepoHasPath ¶
func (*MockProvider) RepoHasPath(_ context.Context, repo *Repository, path string) (bool, error)
type Repository ¶
type Repository struct { Organization string Repository string URL string Branch string SHA string Labels []string RepositoryId interface{} }
An abstract repository from an API provider.
func ListRepos ¶
func ListRepos(ctx context.Context, provider SCMProviderService, filters []argoprojiov1alpha1.SCMProviderGeneratorFilter, cloneProtocol string) ([]*Repository, error)
type SCMProviderService ¶
type SCMProviderService interface { ListRepos(context.Context, string) ([]*Repository, error) RepoHasPath(context.Context, *Repository, string) (bool, error) GetBranches(context.Context, *Repository) ([]*Repository, error) }
Source Files ¶
Click to show internal directories.
Click to hide internal directories.