utils

package
v1.2.0 Latest Latest
Warning

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

Go to latest
Published: Jun 20, 2022 License: LGPL-3.0 Imports: 7 Imported by: 0

README

Reviewpad utilities library

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AbsInt32

func AbsInt32(value int32) int32

func ElementOf

func ElementOf(s []string, str string) bool

func FileExt

func FileExt(fp string) string

func GenerateRandom

func GenerateRandom(size int) int

func GetPullRequestNumber

func GetPullRequestNumber(pullRequest *github.PullRequest) int

func GetPullRequestOwnerName

func GetPullRequestOwnerName(pullRequest *github.PullRequest) string

func GetPullRequestRepoName

func GetPullRequestRepoName(pullRequest *github.PullRequest) string

func HasLinearHistory

func HasLinearHistory(commit *github.Commit) bool

func PaginatedRequest

func PaginatedRequest(
	initFn func() interface{},
	reqFn func(interface{}, int) (interface{}, *github.Response, error),
) (interface{}, error)

func ParseNumPages

func ParseNumPages(resp *github.Response) int

ParseNumPages Given a link header string representing pagination info, returns total number of pages.

func ParseNumPagesFromLink(link string) int

Types

This section is empty.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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