Documentation
¶
Overview ¶
Package github provides GitHub API client operations.
Index ¶
- type Client
- func (c *Client) CreatePullRequest(head, base, title, body string, assignees, reviewers, labels []string) (*github.PullRequest, error)
- func (c *Client) DeleteBranch(branch string) error
- func (c *Client) GetPullRequestByBranch(head, base string) (*github.PullRequest, error)
- func (c *Client) GetPullRequestsByHead(head string) ([]*github.PullRequest, error)
- func (c *Client) ListLabels() ([]*Label, error)
- func (c *Client) MergePullRequest(prNumber int, mergeMethod string) error
- func (c *Client) SetLogger(logger *bullets.Logger)
- func (c *Client) SetRepositoryFromURL(url string) error
- func (c *Client) WaitForWorkflows(timeout time.Duration) (string, error)
- type Label
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
Client represents a GitHub API client wrapper.
func (*Client) CreatePullRequest ¶
func (c *Client) CreatePullRequest( head, base, title, body string, assignees, reviewers, labels []string, ) (*github.PullRequest, error)
CreatePullRequest creates a new pull request with assignees, reviewers, and labels.
func (*Client) DeleteBranch ¶
DeleteBranch deletes a branch from the remote repository.
func (*Client) GetPullRequestByBranch ¶
func (c *Client) GetPullRequestByBranch(head, base string) (*github.PullRequest, error)
GetPullRequestByBranch fetches an existing pull request by head and base branches.
func (*Client) GetPullRequestsByHead ¶
func (c *Client) GetPullRequestsByHead(head string) ([]*github.PullRequest, error)
GetPullRequestsByHead returns all open pull requests for the given head branch.
func (*Client) ListLabels ¶
ListLabels returns all labels for the repository.
func (*Client) MergePullRequest ¶
MergePullRequest merges a pull request using the specified merge method.
func (*Client) SetRepositoryFromURL ¶
SetRepositoryFromURL sets the repository from a git remote URL.
Click to show internal directories.
Click to hide internal directories.