Documentation
¶
Index ¶
- func NewCmdStatus(f *cmdutil.Factory, runF func(*StatusOptions) error) *cobra.Command
- type Event
- type IssueOrPR
- type Notification
- type Results
- type SearchResult
- type StatusGetter
- func (s *StatusGetter) ActualMention(commentURL string) (string, error)
- func (s *StatusGetter) CachedClient(ttl time.Duration) *http.Client
- func (s *StatusGetter) CurrentUsername() (string, error)
- func (s *StatusGetter) HasAuthErrors() bool
- func (s *StatusGetter) LoadEvents() error
- func (s *StatusGetter) LoadNotifications() error
- func (s *StatusGetter) LoadSearchResults() error
- func (s *StatusGetter) ShouldExclude(repo string) bool
- type StatusItem
- type StatusOptions
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewCmdStatus ¶
Types ¶
type Event ¶
type Event struct {
Type string
Org struct {
Login string
}
CreatedAt time.Time `json:"created_at"`
Repo struct {
Name string // owner/repo
}
Payload struct {
Action string
Issue IssueOrPR
PullRequest IssueOrPR `json:"pull_request"`
Comment struct {
Body string
HTMLURL string `json:"html_url"`
}
}
}
type Notification ¶
type Results ¶
type Results []SearchResult
type SearchResult ¶
type StatusGetter ¶
type StatusGetter struct {
Client *http.Client
Org string
Exclude []string
AssignedPRs []StatusItem
AssignedIssues []StatusItem
Mentions []StatusItem
ReviewRequests []StatusItem
RepoActivity []StatusItem
// contains filtered or unexported fields
}
func NewStatusGetter ¶
func NewStatusGetter(client *http.Client, hostname string, opts *StatusOptions) *StatusGetter
func (*StatusGetter) ActualMention ¶
func (s *StatusGetter) ActualMention(commentURL string) (string, error)
func (*StatusGetter) CachedClient ¶
func (s *StatusGetter) CachedClient(ttl time.Duration) *http.Client
func (*StatusGetter) CurrentUsername ¶
func (s *StatusGetter) CurrentUsername() (string, error)
func (*StatusGetter) HasAuthErrors ¶
func (s *StatusGetter) HasAuthErrors() bool
func (*StatusGetter) LoadNotifications ¶
func (s *StatusGetter) LoadNotifications() error
Populate .Mentions
func (*StatusGetter) LoadSearchResults ¶
func (s *StatusGetter) LoadSearchResults() error
Populate .AssignedPRs, .AssignedIssues, .ReviewRequests
func (*StatusGetter) ShouldExclude ¶
func (s *StatusGetter) ShouldExclude(repo string) bool
type StatusItem ¶
type StatusItem struct {
Repository string // owner/repo
Identifier string // eg ungtb10d/cli#1234 or just 1234
Reason string // only used in repo activity
// contains filtered or unexported fields
}
func (StatusItem) Preview ¶
func (s StatusItem) Preview() string
Click to show internal directories.
Click to hide internal directories.