client

package
v0.0.0-...-0d72a47 Latest Latest
Warning

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

Go to latest
Published: Apr 27, 2024 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type GitHubClient

type GitHubClient struct {
	*github.Client
}

func (GitHubClient) GetRepository

func (c GitHubClient) GetRepository(ctx context.Context, repoName string) (*github.Repository, error)

func (GitHubClient) GetRepositoryContents

func (c GitHubClient) GetRepositoryContents(ctx context.Context, path string, repository *github.Repository) ([]string, error)

func (GitHubClient) ListRepositories

func (c GitHubClient) ListRepositories(ctx context.Context, org string) ([]*github.Repository, error)

func (GitHubClient) ListRepositories2

func (c GitHubClient) ListRepositories2(ctx context.Context, org string) ([]*github.Repository, error)

type GitHubService

type GitHubService interface {
	GetRepository(ctx context.Context, name string) (*github.Repository, error)
	ListRepositories(ctx context.Context, org string) ([]*github.Repository, error)
	ListRepositories2(ctx context.Context, org string) ([]*github.Repository, error)
	GetRepositoryContents(ctx context.Context, filepath string, repository *github.Repository) ([]string, error)
}

func NewGitHubClient

func NewGitHubClient(opts ...Options) GitHubService

type Options

type Options func(*GitHubClient) error

func WithAuthToken

func WithAuthToken(token string) Options

type Repository

type Repository struct {
	Name  string
	Owner string
}

Jump to

Keyboard shortcuts

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