Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetInstallationID ¶
GetInstallationID grabs install_id for the user
func GetInstalledRepos ¶
func GetInstalledRepos(token string, installID *int64) ([]*github.Repository, error)
GetInstalledRepos returns the repos the GitHub App is installed on
Types ¶
type GQLRepo ¶
type GQLRepo struct {
GQLNode
DatabaseID int64 `json:"id"`
NameWithOwner string `json:"nameWithOwner"`
IsPrivate bool `json:"is_private"`
IsFork bool `json:"is_fork"`
Description string `json:"description"`
Owner struct {
Login string `json:"login"`
AvatarURL string `json:"avatar_url"`
} `json:"owner"`
Languages struct {
Nodes []*GQLNode `json:"nodes"`
} `graphql:"languages(first: 4)" json:"languages"`
Collaborators struct {
Nodes []GQLUser `json:"nodes"`
} `json:"collaborators"`
DefaultBranchRef struct {
Name string `json:"name"`
Target struct {
Commit struct {
CommittedDate string `json:"committed_date"`
OID string `json:"commit_sha"`
Message string `json:"message"`
Author struct {
User struct {
Login string `json:"login"`
Name string `json:"name"`
} `json:"user"`
} `json:"author"`
Tree struct {
Entries []struct {
GQLNode
Type string `json:"type"`
} `json:"entries"`
} `json:"tree"`
} `graphql:"... on Commit" json:"commit"`
} `json:"target"`
} `json:"default_branch"`
}
GQLRepo is Repository object
func QueryRepoByName ¶
QueryRepoByName fetches repo details, for an installation the repo must be added to it
func QueryRepos ¶
QueryRepos runs custom query for repos and their commits, collaborators, and root tree on default branch
Click to show internal directories.
Click to hide internal directories.