Documentation
¶
Index ¶
- func New(token, host string) (provider.Provider, error)
- type Client
- func (c *Client) CloneURL(protocol, fullName string) string
- func (c *Client) DetectOwner(ctx context.Context, owner string) (bool, error)
- func (c *Client) Host() string
- func (c *Client) ListPullRequests(ctx context.Context, owner, repoName string, opts provider.ListPROptions) ([]*provider.PullRequest, error)
- func (c *Client) ListRepos(ctx context.Context, owner string, opts provider.ListOptions) ([]*provider.Repo, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
func (*Client) CloneURL ¶
CloneURL returns the git clone URL for a repo identified by its full name ("owner/repo"), using "ssh" or "https". GitHub's format:
ssh: git@<host>:owner/repo.git https: https://<host>/owner/repo.git
func (*Client) DetectOwner ¶
DetectOwner reports whether the given owner name is an organization (true) or a user (false). Uses a single lightweight GET to /orgs/{owner}; any non-404 error is returned as-is.
func (*Client) ListPullRequests ¶
func (c *Client) ListPullRequests(ctx context.Context, owner, repoName string, opts provider.ListPROptions) ([]*provider.PullRequest, error)
Click to show internal directories.
Click to hide internal directories.