gogithub

package module
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Dec 11, 2023 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

View Source
const (
	UsernameDependabot = "dependabot[bot]"
	UserIDDependabot   = 49699333

	ParamPerPageMax     = 100
	ParamPerPageDefault = 30

	IssueStateOpen = "open"
	IssueIsPR      = "pr"
)

Variables

View Source
var (
	ErrIssueIsNotSet                 = errors.New("issue is not set")
	ErrUserIsNotSet                  = errors.New("user is not set")
	ErrUserLoginIsNotSet             = errors.New("user login is not set")
	ErrIssueCreatedAtIsNotSet        = errors.New("issue created at is not set")
	ErrIssueCreatedAtGetTimeIsNotSet = errors.New("issue created at gettime is not set")
)

Functions

This section is empty.

Types

type Client

type Client struct {
	*github.Client
}

func NewClient

func NewClient(httpClient *http.Client) *Client

func (*Client) SearchIssues

func (c *Client) SearchIssues(ctx context.Context, qry Query, opts *github.SearchOptions) (*github.IssuesSearchResult, *github.Response, error)

func (*Client) SearchIssuesAll

func (c *Client) SearchIssuesAll(ctx context.Context, qry Query, opts *github.SearchOptions) (Issues, error)

func (*Client) SearchOpenPullRequests

func (c *Client) SearchOpenPullRequests(ctx context.Context, username string, opts *github.SearchOptions) (*github.IssuesSearchResult, *github.Response, error)

type Issue

type Issue struct {
	*github.Issue
}

func (*Issue) AuthorUsername

func (is *Issue) AuthorUsername() (string, error)

func (*Issue) CreatedAge

func (is *Issue) CreatedAge() (time.Duration, error)

func (*Issue) CreatedTime

func (is *Issue) CreatedTime() (time.Time, error)

func (*Issue) MustAuthorUsername

func (is *Issue) MustAuthorUsername() string

type Issues

type Issues []*github.Issue

func (Issues) Table

func (iss Issues) Table() (*table.Table, error)

type Query

type Query map[string]string

func (Query) Encode

func (q Query) Encode() string

Directories

Path Synopsis
pullrequest

Jump to

Keyboard shortcuts

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