Documentation ¶
Index ¶
- Variables
- func LoadReviewpadFile(ctx context.Context, logger *logrus.Entry, ...) (*engine.ReviewpadFile, error)
- func LogErr(err error)
- func LogFatalErr(err error)
- func ReviewpadFileChanged(ctx context.Context, githubClient *reviewpad_gh.GithubClient, filePath string, ...) (bool, error)
- func ValidateBranch(branch *github.PullRequestBranch) error
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ErrBranchNil = errors.New("branch is nil") ErrBranchRefNil = errors.New("branch ref is nil") ErrBranchRepoNil = errors.New("branch repo is nil") ErrBranchRepoNameNil = errors.New("branch repo name is nil") ErrBranchRepoOwnerNil = errors.New("branch repo owner is nil") ErrBranchRepoOwnerLoginNil = errors.New("branch repo owner login is nil") )
Functions ¶
func LoadReviewpadFile ¶
func LoadReviewpadFile(ctx context.Context, logger *logrus.Entry, githubClient *reviewpad_gh.GithubClient, filePath string, branch *github.PullRequestBranch) (*engine.ReviewpadFile, error)
func LogFatalErr ¶
func LogFatalErr(err error)
func ReviewpadFileChanged ¶
func ReviewpadFileChanged(ctx context.Context, githubClient *reviewpad_gh.GithubClient, filePath string, pullRequest *github.PullRequest) (bool, error)
reviewpad-an: experimental ReviewpadFileChanges checks if a file path was changed in a pull request. The way this is done depends on the number of files changed in the pull request. If the number of files changed is greater than pullRequestFileLimit, then we download both files using the filePath and check their contents. This strategy assumes that the file path exists in the head branch. Otherwise, we download the pull request files and check the filePath exists in them.
func ValidateBranch ¶
func ValidateBranch(branch *github.PullRequestBranch) error
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.