Documentation
¶
Index ¶
- func LoadLinguistLanguages() (map[string]struct{ ... }, error)
- func Request(token, query string, variables map[string]interface{}) (*http.Response, error)
- type Data
- type DataUser
- type GlobalStats
- type GlobalStatsResponse
- type GraphQLPRFilesResponse
- type GraphQLResponse
- type GraphQLUserResponse
- type HistoryResponse
- type LanguageEdge
- type LanguageNode
- type Languages
- type LinguistLanguage
- type OrganizationNode
- type Organizations
- type PRFileNode
- type PRFiles
- type PRRepositoryDetail
- type PageInfo
- type PrimaryLanguage
- type Repositories
- type RepositoryEdge
- type RepositoryNode
- type Result
- type ResultLanguage
- type ResultRepository
- type StreakStats
- type UserPullRequestEdge
- type UserPullRequestNode
- type UserPullRequests
- type UserRepositories
- type UserRepositoryEdge
- type UserRepositoryNode
- type Viewer
- type ViewerUser
- type YearlyContributionResponse
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func LoadLinguistLanguages ¶ added in v1.0.3
Types ¶
type DataUser ¶
type DataUser struct {
Viewer ViewerUser `json:"viewer"`
}
type GlobalStats ¶ added in v1.1.0
type GlobalStats struct {
TotalStars int
TotalCommits int
TotalPRs int
TotalIssues int
TotalReviews int
MergedPRs int
Followers int
TotalRepos int
TotalForks int
}
func FetchGlobalStats ¶ added in v1.1.0
func FetchGlobalStats(username, token string) (*GlobalStats, error)
type GlobalStatsResponse ¶ added in v1.1.0
type GlobalStatsResponse struct {
Data struct {
User struct {
Followers struct {
TotalCount int `json:"totalCount"`
} `json:"followers"`
Issues struct {
TotalCount int `json:"totalCount"`
} `json:"issues"`
PullRequests struct {
TotalCount int `json:"totalCount"`
} `json:"pullRequests"`
MergedPRs struct {
TotalCount int `json:"totalCount"`
} `json:"mergedPRs"`
ContributionsCollection struct {
TotalPullRequestReviewContributions int `json:"totalPullRequestReviewContributions"`
TotalCommitContributions int `json:"totalCommitContributions"`
} `json:"contributionsCollection"`
Repositories struct {
TotalCount int `json:"totalCount"`
Nodes []struct {
StargazerCount int `json:"stargazerCount"`
ForkCount int `json:"forkCount"`
} `json:"nodes"`
} `json:"repositories"`
} `json:"user"`
} `json:"data"`
}
type GraphQLPRFilesResponse ¶ added in v1.0.3
type GraphQLPRFilesResponse struct {
Data struct {
Node struct {
Files PRFiles `json:"files"`
} `json:"node"`
} `json:"data"`
}
type GraphQLResponse ¶
type GraphQLResponse struct {
Data Data `json:"data"`
}
type GraphQLUserResponse ¶
type GraphQLUserResponse struct {
Data DataUser `json:"data"`
}
type HistoryResponse ¶ added in v1.1.0
type HistoryResponse struct {
Data struct {
User struct {
CreatedAt string `json:"createdAt"`
} `json:"user"`
} `json:"data"`
}
type LanguageEdge ¶
type LanguageEdge struct {
Node LanguageNode `json:"node"`
Size int `json:"size"`
}
type LanguageNode ¶
type Languages ¶
type Languages struct {
Edges []LanguageEdge `json:"edges"`
}
type LinguistLanguage ¶ added in v1.0.3
type OrganizationNode ¶
type OrganizationNode struct {
Login string `json:"login"`
CanAdminister bool `json:"viewerCanAdminister"`
Repositories Repositories `json:"repositories"`
}
type Organizations ¶
type Organizations struct {
Nodes []OrganizationNode `json:"nodes"`
PageInfo PageInfo `json:"pageInfo"`
}
type PRFileNode ¶ added in v1.0.3
type PRFiles ¶ added in v1.0.3
type PRFiles struct {
Nodes []PRFileNode `json:"nodes"`
PageInfo PageInfo `json:"pageInfo"`
}
type PRRepositoryDetail ¶ added in v1.0.3
type PrimaryLanguage ¶
type PrimaryLanguage struct {
Name string `json:"name"`
}
type Repositories ¶
type Repositories struct {
Edges []RepositoryEdge `json:"edges"`
}
type RepositoryEdge ¶
type RepositoryEdge struct {
Node RepositoryNode `json:"node"`
}
type RepositoryNode ¶
type RepositoryNode struct {
Name string `json:"name"`
NameWithOwner string `json:"nameWithOwner"`
PrimaryLanguage PrimaryLanguage `json:"primaryLanguage"`
Languages Languages `json:"languages"`
}
type Result ¶
type Result struct {
Repositories []*ResultRepository
}
func FetchOrganizations ¶
type ResultLanguage ¶
type ResultRepository ¶
type StreakStats ¶ added in v1.1.0
type StreakStats struct {
TotalContributions int
CurrentStreak int
LongestStreak int
AccountCreated string
CurrentStart string
CurrentEnd string
LongestStart string
LongestEnd string
}
func FetchContributionStats ¶ added in v1.1.0
func FetchContributionStats(username, token string) (*StreakStats, error)
type UserPullRequestEdge ¶ added in v1.0.3
type UserPullRequestEdge struct {
Node UserPullRequestNode `json:"node"`
}
type UserPullRequestNode ¶ added in v1.0.3
type UserPullRequestNode struct {
ID string `json:"id"`
Title string `json:"title"`
Repository PRRepositoryDetail `json:"repository"`
Files PRFiles `json:"files"`
}
type UserPullRequests ¶ added in v1.0.3
type UserPullRequests struct {
Edges []UserPullRequestEdge `json:"edges"`
PageInfo PageInfo `json:"pageInfo"`
}
type UserRepositories ¶ added in v1.0.3
type UserRepositories struct {
Edges []UserRepositoryEdge `json:"edges"`
PageInfo PageInfo `json:"pageInfo"`
}
type UserRepositoryEdge ¶ added in v1.0.3
type UserRepositoryEdge struct {
Node UserRepositoryNode `json:"node"`
}
type UserRepositoryNode ¶ added in v1.0.3
type UserRepositoryNode struct {
Name string `json:"name"`
NameWithOwner string `json:"nameWithOwner"`
IsFork bool `json:"isFork"`
PrimaryLanguage PrimaryLanguage `json:"primaryLanguage"`
Languages Languages `json:"languages"`
}
type Viewer ¶
type Viewer struct {
Organizations Organizations `json:"organizations"`
}
type ViewerUser ¶
type ViewerUser struct {
Repositories UserRepositories `json:"repositories"`
PullRequests UserPullRequests `json:"pullRequests"`
}
type YearlyContributionResponse ¶ added in v1.1.0
type YearlyContributionResponse struct {
Data struct {
User struct {
ContributionsCollection struct {
ContributionCalendar struct {
TotalContributions int `json:"totalContributions"`
Weeks []struct {
ContributionDays []struct {
ContributionCount int `json:"contributionCount"`
Date string `json:"date"`
} `json:"contributionDays"`
} `json:"weeks"`
} `json:"contributionCalendar"`
} `json:"contributionsCollection"`
} `json:"user"`
} `json:"data"`
}
Click to show internal directories.
Click to hide internal directories.