Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Info ¶
type Info struct { // Updates is the number of available updates. Updates int // PackageDetails are optional details for the packages that updates are // available for. PackageDetails PackageDetails }
Info contains information about available updates.
type Module ¶
type Module struct {
// contains filtered or unexported fields
}
Module is a module for displaying currently available updates in the bar.
func New ¶
New creates a new *Module with the given update count provider. By default, the module will refresh the update counts every hour. The refresh interval can be configured using `Every`.
func (*Module) Every ¶
Every configures the refresh interval for the module. Passing a zero interval will disable refreshing.
type PackageDetail ¶
type PackageDetail struct { // PackageName is the name of the package. PackageName string // CurrentVersion is the currently installed package version. CurrentVersion string // TargetVersion is the version of the available package update. TargetVersion string }
PackageDetail contains information about a single package update.
func (PackageDetail) String ¶
func (d PackageDetail) String() string
String implements fmt.Stringer.
type PackageDetails ¶
type PackageDetails []PackageDetail
PackageDetails contains details about package updates.
func (PackageDetails) String ¶
func (d PackageDetails) String() string
String implements fmt.Stringer.
type ProviderFunc ¶
ProviderFunc is a func that satisfies the Provider interface.
func (ProviderFunc) Updates ¶
func (f ProviderFunc) Updates() (Info, error)
Updates implements Provider.