upstream

package
v0.1.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 27, 2022 License: GPL-2.0 Imports: 12 Imported by: 1 module, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type GithubClient

type GithubClient struct {
	// contains filtered or unexported fields
}

func NewGithubClient

func NewGithubClient(client *github.Client) *GithubClient

func NewGithubClientWithToken

func NewGithubClientWithToken(token string) *GithubClient

func (*GithubClient) GetRepositories

func (c *GithubClient) GetRepositories(ctx context.Context, owners []string, fetchUserRepos bool) ([]HostRepository, error)

type GithubRepository

type GithubRepository struct {
	github.Repository
}

func (*GithubRepository) GetBrowserHomepageURL

func (r *GithubRepository) GetBrowserHomepageURL() string

func (*GithubRepository) GetBrowserPullRequestsURL

func (r *GithubRepository) GetBrowserPullRequestsURL() string

func (*GithubRepository) GetCIURL added in v0.1.0

func (r *GithubRepository) GetCIURL() string

func (*GithubRepository) GetDescription

func (r *GithubRepository) GetDescription() string

func (*GithubRepository) GetHTTPSCloneURL

func (r *GithubRepository) GetHTTPSCloneURL() string

func (*GithubRepository) GetIssuesURL added in v0.1.0

func (r *GithubRepository) GetIssuesURL() string

func (*GithubRepository) GetName

func (r *GithubRepository) GetName() string

func (*GithubRepository) GetOrgURL added in v0.1.0

func (r *GithubRepository) GetOrgURL() string

func (*GithubRepository) GetOwner

func (r *GithubRepository) GetOwner() string

func (*GithubRepository) GetProvider

func (r *GithubRepository) GetProvider() string

func (*GithubRepository) GetReleasesURL added in v0.1.0

func (r *GithubRepository) GetReleasesURL() string

func (*GithubRepository) GetSSHCloneURL

func (r *GithubRepository) GetSSHCloneURL() string

func (*GithubRepository) GetSettingsURL added in v0.1.0

func (r *GithubRepository) GetSettingsURL() string

type GitlabClient

type GitlabClient struct {
	// contains filtered or unexported fields
}

func NewGitlabClient

func NewGitlabClient(client *gitlab.Client) *GitlabClient

func NewGitlabClientWithToken

func NewGitlabClientWithToken(token string) (*GitlabClient, error)

func (*GitlabClient) GetRepositories

func (c *GitlabClient) GetRepositories(ctx context.Context, groups []string, fetchUserRepos bool) ([]HostRepository, error)

type GitlabProject

type GitlabProject struct {
	gitlab.Project
	Username string
}

func (*GitlabProject) GetBrowserHomepageURL

func (r *GitlabProject) GetBrowserHomepageURL() string

func (*GitlabProject) GetBrowserPullRequestsURL

func (r *GitlabProject) GetBrowserPullRequestsURL() string

func (*GitlabProject) GetCIURL added in v0.1.0

func (r *GitlabProject) GetCIURL() string

func (*GitlabProject) GetDescription

func (r *GitlabProject) GetDescription() string

func (*GitlabProject) GetHTTPSCloneURL

func (r *GitlabProject) GetHTTPSCloneURL() string

func (*GitlabProject) GetIssuesURL added in v0.1.0

func (r *GitlabProject) GetIssuesURL() string

func (*GitlabProject) GetName

func (r *GitlabProject) GetName() string

func (*GitlabProject) GetOrgURL added in v0.1.0

func (r *GitlabProject) GetOrgURL() string

func (*GitlabProject) GetOwner

func (r *GitlabProject) GetOwner() string

func (*GitlabProject) GetProvider

func (r *GitlabProject) GetProvider() string

func (*GitlabProject) GetReleasesURL added in v0.1.0

func (r *GitlabProject) GetReleasesURL() string

func (*GitlabProject) GetSSHCloneURL

func (r *GitlabProject) GetSSHCloneURL() string

func (*GitlabProject) GetSettingsURL added in v0.1.0

func (r *GitlabProject) GetSettingsURL() string

type HostRepositories

type HostRepositories []HostRepository

func (HostRepositories) DeDuplicate

func (hr HostRepositories) DeDuplicate() []HostRepository

type HostRepository

type HostRepository interface {
	GetProvider() string
	GetName() string
	GetOwner() string
	GetDescription() string
	GetBrowserHomepageURL() string
	GetBrowserPullRequestsURL() string
	GetHTTPSCloneURL() string
	GetSSHCloneURL() string
	GetOrgURL() string
	GetIssuesURL() string
	GetCIURL() string
	GetReleasesURL() string
	GetSettingsURL() string
}

type MockClient

type MockClient struct {
	// contains filtered or unexported fields
}

func NewMockClient

func NewMockClient() *MockClient

func (*MockClient) GetRepositories

func (c *MockClient) GetRepositories(ctx context.Context, owners []string, fetchAuthenticationUserRepos bool) ([]HostRepository, error)

func (*MockClient) WithRepositories

func (c *MockClient) WithRepositories(repos []MockRepository) *MockClient

type MockRepository

type MockRepository struct {
	Provider               string
	Owner                  string
	Name                   string
	Description            string
	BrowserHomepageURL     string
	BrowserPullRequestsURL string
	HTTPSCloneURL          string
	SSHCloneURL            string
	OrgURL                 string
	IssuesURL              string
	CIURL                  string
	ReleasesURL            string
	SettingsURL            string
}

func (*MockRepository) GetBrowserHomepageURL

func (r *MockRepository) GetBrowserHomepageURL() string

func (*MockRepository) GetBrowserPullRequestsURL

func (r *MockRepository) GetBrowserPullRequestsURL() string

func (*MockRepository) GetCIURL added in v0.1.0

func (r *MockRepository) GetCIURL() string

func (*MockRepository) GetDescription

func (r *MockRepository) GetDescription() string

func (*MockRepository) GetHTTPSCloneURL

func (r *MockRepository) GetHTTPSCloneURL() string

func (*MockRepository) GetIssuesURL added in v0.1.0

func (r *MockRepository) GetIssuesURL() string

func (*MockRepository) GetName

func (r *MockRepository) GetName() string

func (*MockRepository) GetOrgURL added in v0.1.0

func (r *MockRepository) GetOrgURL() string

func (*MockRepository) GetOwner

func (r *MockRepository) GetOwner() string

func (*MockRepository) GetProvider

func (r *MockRepository) GetProvider() string

func (*MockRepository) GetReleasesURL added in v0.1.0

func (r *MockRepository) GetReleasesURL() string

func (*MockRepository) GetSSHCloneURL

func (r *MockRepository) GetSSHCloneURL() string

func (*MockRepository) GetSettingsURL added in v0.1.0

func (r *MockRepository) GetSettingsURL() string

type RepositoryHostClient

type RepositoryHostClient interface {
	GetRepositories(ctx context.Context, owners []string, fetchUserRepos bool) ([]HostRepository, error)
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL