Documentation
¶
Overview ¶
githubtrending is a client-side SDK for huchenme/github-trending-api (https://github.com/huchenme/github-trending-api), which provides unofficial APIs for GitHub trending projects and developers.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Developer ¶
type Developer struct {
Username string `json:"username"`
DisplayName string `json:"name"`
Type string `json:"type"`
URL string `json:"url"`
Avatar string `json:"avatar"`
Repo struct {
Name string `json:"name"`
Description string `json:"description"`
URL string `json:"url"`
} `json:"repo"`
}
Developer consists of basic info of a GitHub trending developer and his/her trending repository.
func GetDevelopers ¶
GetDevelopers retrieves a list of GitHub trending developers from the API.
type Repository ¶
type Repository struct {
Author string `json:"author"`
Name string `json:"name"`
Avatar string `json:"avatar"`
URL string `json:"url"`
Description string `json:"description"`
Language string `json:"language,omitempty"`
LanguageColor string `json:"languageColor,omitempty"`
Stars int `json:"stars"`
Forks int `json:"forks"`
CurrentPeriodStars int `json:"currentPeriodStars"`
Owner []struct {
Username string `json:"username"`
Href string `json:"href"`
Avatar string `json:"avatar"`
} `json:"builtBy"`
}
Repository consists of basic info of a GitHub trending repository and its developer.
func GetRepositories ¶
func GetRepositories() (repos []*Repository, err error)
GetRepositories retrieves a list of GitHub trending repositories from the API.
func (Repository) String ¶
func (r Repository) String() string
Click to show internal directories.
Click to hide internal directories.