Documentation
¶
Overview ¶
Package pr provides GitHub pull request operations.
Index ¶
- func AddPRReviewers(ctx context.Context, gh *github.Client, owner, repo string, number int, ...) (*github.PullRequest, error)
- func ClosePR(ctx context.Context, gh *github.Client, owner, repo string, number int) (*github.PullRequest, error)
- func CreatePR(ctx context.Context, gh *github.Client, ...) (*github.PullRequest, error)
- func GetPR(ctx context.Context, gh *github.Client, owner, repo string, number int) (*github.PullRequest, error)
- func ListPRComments(ctx context.Context, gh *github.Client, owner, repo string, number int) ([]*github.PullRequestComment, error)
- func ListPRFiles(ctx context.Context, gh *github.Client, owner, repo string, number int) ([]*github.CommitFile, error)
- func ListPRs(ctx context.Context, gh *github.Client, owner, repo string, ...) ([]*github.PullRequest, error)
- func MergePR(ctx context.Context, gh *github.Client, owner, repo string, number int, ...) (*github.PullRequestMergeResult, error)
- type PRError
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AddPRReviewers ¶
func AddPRReviewers(ctx context.Context, gh *github.Client, owner, repo string, number int, reviewers, teamReviewers []string) (*github.PullRequest, error)
AddPRReviewers adds reviewers to a pull request.
func ClosePR ¶
func ClosePR(ctx context.Context, gh *github.Client, owner, repo string, number int) (*github.PullRequest, error)
ClosePR closes a pull request without merging.
func CreatePR ¶
func CreatePR(ctx context.Context, gh *github.Client, upstreamOwner, upstreamRepo, forkOwner, branch, baseBranch, title, body string) (*github.PullRequest, error)
CreatePR creates a pull request.
func GetPR ¶
func GetPR(ctx context.Context, gh *github.Client, owner, repo string, number int) (*github.PullRequest, error)
GetPR retrieves a pull request by number.
func ListPRComments ¶
func ListPRComments(ctx context.Context, gh *github.Client, owner, repo string, number int) ([]*github.PullRequestComment, error)
ListPRComments lists comments on a pull request.
func ListPRFiles ¶
func ListPRFiles(ctx context.Context, gh *github.Client, owner, repo string, number int) ([]*github.CommitFile, error)
ListPRFiles lists files changed in a pull request.
Types ¶
Click to show internal directories.
Click to hide internal directories.