github

package
v0.0.4 Latest Latest
Warning

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

Go to latest
Published: Nov 17, 2018 License: MIT Imports: 13 Imported by: 0

Documentation

Index

Constants

View Source
const (
	VALIDATION_FAILED_MSG = "Validation Failed"
	NO_COMMITS_MSG_PREFIX = "No commits between"
	CODE_INVALID          = "invalid"
)

Variables

This section is empty.

Functions

func RenderPullRequestTpl added in v0.0.2

func RenderPullRequestTpl(initMsg, cs, base, head string, commitLogs string) (string, error)

Types

type AuthorizationsService added in v0.0.3

type AuthorizationsService interface {
	Create(ctx context.Context, authReq *github.AuthorizationRequest) (*github.Authorization, *github.Response, error)
	List(ctx context.Context, options *github.ListOptions) ([]*github.Authorization, *github.Response, error)
}

type Client

type Client struct {
	ListOptions *github.ListOptions
	// contains filtered or unexported fields
}

func (*Client) GetAuthorizations added in v0.0.3

func (c *Client) GetAuthorizations() service.AuthorizationsService

func (*Client) GetIssues

func (c *Client) GetIssues() service.IssuesService

func (*Client) GetProjects added in v0.0.3

func (c *Client) GetProjects() service.ProjectsService

func (*Client) GetPullRequests

func (c *Client) GetPullRequests() service.PullRequestsService

func (*Client) GetRepositories added in v0.0.3

func (c *Client) GetRepositories() service.RepositoriesService

type ClientBuilder added in v0.0.3

type ClientBuilder struct{}

func (*ClientBuilder) GetType added in v0.0.3

func (cb *ClientBuilder) GetType() string

func (*ClientBuilder) New added in v0.0.3

func (cb *ClientBuilder) New(ctx context.Context, serviceConfig *etc.ServiceConfig) (service.Client, error)

func (*ClientBuilder) NewViaBasicAuth added in v0.0.3

func (cb *ClientBuilder) NewViaBasicAuth(ctx context.Context, serviceConfig *etc.ServiceConfig, user, pass string) (service.Client, error)

type Issue

type Issue struct {
	*github.Issue
}

type IssuesService added in v0.0.3

type IssuesService interface {
	ListByRepo(ctx context.Context, owner, repo string, opt *github.IssueListByRepoOptions) ([]*github.Issue, *github.Response, error)
}

type PullRequest

type PullRequest struct {
	*github.PullRequest
}

type PullRequestsService added in v0.0.3

type PullRequestsService interface {
	List(ctx context.Context, owner, repo string, opt *github.PullRequestListOptions) ([]*github.PullRequest, *github.Response, error)
	Create(ctx context.Context, owner string, repo string, pull *github.NewPullRequest) (*github.PullRequest, *github.Response, error)
}

type RawClient added in v0.0.2

type RawClient interface {
	GetRepositories() RepositoriesService
	GetPullRequests() PullRequestsService
	GetIssues() IssuesService
	GetAuthorizations() AuthorizationsService
	SetBaseURL(baseUrl *url.URL)
}

type RepositoriesService added in v0.0.3

type RepositoriesService interface {
	Get(ctx context.Context, owner, repo string) (*github.Repository, *github.Response, error)
	Create(ctx context.Context, org string, repo *github.Repository) (*github.Repository, *github.Response, error)
	CreateRelease(ctx context.Context, owner, repo string, release *github.RepositoryRelease) (*github.RepositoryRelease, *github.Response, error)
}

type Repository

type Repository struct {
	*github.Repository
}

Jump to

Keyboard shortcuts

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