gitea

package
v0.7.0 Latest Latest
Warning

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

Go to latest
Published: Feb 1, 2022 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

type Client struct {
	// contains filtered or unexported fields
}

Client is a gitea client.

func NewClient

func NewClient(baseURL, token string, preverified bool) (*Client, error)

NewClient returns a new gitea client.

func (*Client) Branches

func (c *Client) Branches(owner string, name string) ([]vcs.Branch, error)

Branches returns a list of branches for the given repository.

func (*Client) GetUsername

func (c *Client) GetUsername() (string, error)

GetUsername returns the username of the authenticated user.

func (*Client) History

func (c *Client) History(repo vcs.Repo, max int, since time.Time) ([]vcs.Commit, error)

History returns a list of commits for the given repository.

func (*Client) IssueURL

func (c *Client) IssueURL(owner string, name string, number int) string

IssueURL returns the URL to the issue with the given number.

func (*Client) Issues

func (c *Client) Issues(owner string, name string) ([]vcs.Issue, error)

Issues returns a list of issues for the given repository.

func (*Client) PullRequests

func (c *Client) PullRequests(owner string, name string) ([]vcs.PullRequest, error)

PullRequests returns a list of pull requests for the given repository.

func (*Client) Repositories

func (c *Client) Repositories(owner string) ([]vcs.Repo, error)

Repositories returns a list of repositories for the given user.

func (*Client) Repository

func (c *Client) Repository(owner string, name string) (vcs.Repo, error)

Repository returns the repository with the given name.

Jump to

Keyboard shortcuts

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