Documentation ¶
Index ¶
- Constants
- Variables
- type Client
- func (c *Client) ForkRepository(ctx context.Context, repoName string) error
- func (c *Client) GetRepository(ctx context.Context, owner, repoName string) (*github.Repository, error)
- func (c *Client) GetUserRepositoryFork(ctx context.Context, owner string, repoName string) (*github.Repository, error)
- func (c *Client) ListRepositoryForks(ctx context.Context, repoName string) ([]*github.Repository, error)
- func (c *Client) RenameRepository(ctx context.Context, owner, name, newName string) error
- type RepositoryService
Constants ¶
View Source
const (
ACKOrg = "aws-controllers-k8s"
)
Variables ¶
View Source
var ErrForkNotFound = errors.New("fork not found")
Functions ¶
This section is empty.
Types ¶
type Client ¶
Client is a github.Client wrapper
func (*Client) ForkRepository ¶
ForkRepository forks a Github repository from the ACK organisation.
func (*Client) GetRepository ¶
func (c *Client) GetRepository(ctx context.Context, owner, repoName string) (*github.Repository, error)
GetRepository takes an owner and repoName and returns the Github repository informations
func (*Client) GetUserRepositoryFork ¶
func (c *Client) GetUserRepositoryFork(ctx context.Context, owner string, repoName string) (*github.Repository, error)
GetUserRepositoryFork takes an ACK repository name and tries to find it fork in the user public repositories.
func (*Client) ListRepositoryForks ¶
func (c *Client) ListRepositoryForks(ctx context.Context, repoName string) ([]*github.Repository, error)
ListRepositoryForks list the forks of a given repository in the ACK organisation. It returns a list fork information which includes the owner and the fork name (forkInfo).
type RepositoryService ¶
type RepositoryService interface { ForkRepository(ctx context.Context, repoName string) error RenameRepository(ctx context.Context, owner, name, newName string) error GetRepository(ctx context.Context, owner, repoName string) (*github.Repository, error) ListRepositoryForks(ctx context.Context, repoName string) ([]*github.Repository, error) GetUserRepositoryFork(ctx context.Context, owner, repoName string) (*github.Repository, error) }
RepositoryService is the interface implemented by the Github client wrapper. It exposes functionalities to simplify the interactions with the repository endpoint of Github APIv3
Click to show internal directories.
Click to hide internal directories.