Documentation ¶
Index ¶
- Constants
- func AutoUpdateChannel() string
- func GoUpdateActivityWrap(update ActivityUpdate, debugStr string)
- func IsAutoUpdateEnabled() bool
- func IsTelemetryEnabled() bool
- func MarkActivityAsUploaded(ctx context.Context, activityArr []*ActivityType) error
- func UpdateActivity(ctx context.Context, update ActivityUpdate) error
- type ActivityDisplayType
- type ActivityType
- type ActivityUpdate
- type TelemetryData
Constants ¶
View Source
const MaxTzNameLen = 50
Variables ¶
This section is empty.
Functions ¶
func AutoUpdateChannel ¶
func AutoUpdateChannel() string
func GoUpdateActivityWrap ¶
func GoUpdateActivityWrap(update ActivityUpdate, debugStr string)
Wraps UpdateCurrentActivity, spawns goroutine, and logs errors
func IsAutoUpdateEnabled ¶
func IsAutoUpdateEnabled() bool
func IsTelemetryEnabled ¶
func IsTelemetryEnabled() bool
func MarkActivityAsUploaded ¶
func MarkActivityAsUploaded(ctx context.Context, activityArr []*ActivityType) error
func UpdateActivity ¶
func UpdateActivity(ctx context.Context, update ActivityUpdate) error
Types ¶
type ActivityDisplayType ¶ added in v0.9.3
type ActivityType ¶
type ActivityType struct { Day string `json:"day"` Uploaded bool `json:"-"` TData TelemetryData `json:"tdata"` TzName string `json:"tzname"` TzOffset int `json:"tzoffset"` ClientVersion string `json:"clientversion"` ClientArch string `json:"clientarch"` BuildTime string `json:"buildtime"` OSRelease string `json:"osrelease"` }
func GetNonUploadedActivity ¶
func GetNonUploadedActivity(ctx context.Context) ([]*ActivityType, error)
type ActivityUpdate ¶
type ActivityUpdate struct { FgMinutes int `json:"fgminutes,omitempty"` ActiveMinutes int `json:"activeminutes,omitempty"` OpenMinutes int `json:"openminutes,omitempty"` NumTabs int `json:"numtabs,omitempty"` NewTab int `json:"newtab,omitempty"` NumBlocks int `json:"numblocks,omitempty"` NumWindows int `json:"numwindows,omitempty"` NumSSHConn int `json:"numsshconn,omitempty"` NumWSLConn int `json:"numwslconn,omitempty"` NumMagnify int `json:"nummagnify,omitempty"` NumPanics int `json:"numpanics,omitempty"` Startup int `json:"startup,omitempty"` Shutdown int `json:"shutdown,omitempty"` SetTabTheme int `json:"settabtheme,omitempty"` BuildTime string `json:"buildtime,omitempty"` Displays []ActivityDisplayType `json:"displays,omitempty"` Renderers map[string]int `json:"renderers,omitempty"` WshCmds map[string]int `json:"wshcmds,omitempty"` Conn map[string]int `json:"conn,omitempty"` }
type TelemetryData ¶
type TelemetryData struct { ActiveMinutes int `json:"activeminutes"` FgMinutes int `json:"fgminutes"` OpenMinutes int `json:"openminutes"` NumTabs int `json:"numtabs"` NumBlocks int `json:"numblocks,omitempty"` NumWindows int `json:"numwindows,omitempty"` NumSSHConn int `json:"numsshconn,omitempty"` NumWSLConn int `json:"numwslconn,omitempty"` NumMagnify int `json:"nummagnify,omitempty"` NewTab int `json:"newtab"` NumStartup int `json:"numstartup,omitempty"` NumShutdown int `json:"numshutdown,omitempty"` NumPanics int `json:"numpanics,omitempty"` SetTabTheme int `json:"settabtheme,omitempty"` Displays []ActivityDisplayType `json:"displays,omitempty"` Renderers map[string]int `json:"renderers,omitempty"` WshCmds map[string]int `json:"wshcmds,omitempty"` Conn map[string]int `json:"conn,omitempty"` }
func (*TelemetryData) Scan ¶
func (tdata *TelemetryData) Scan(val interface{}) error
Click to show internal directories.
Click to hide internal directories.