config

package
v0.1.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 3, 2024 License: MIT Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	Path string `json:"path"`

	Location  string  `json:"location"`
	Latitude  float64 `json:"latitude"`
	Longitude float64 `json:"longitude"`

	Colors colors.Colors `json:"-"`
	Format string        `json:"format"`
	Units  string        `json:"units"`

	IconType string      `json:"icon_type"`
	Icons    icons.Icons `json:"icons"`

	Forecaster ForecastProviders `json:"forecaster"`
	Geocoder   GeocodeProviders  `json:"geocoder"`

	Interval int `json:"interval"`
}

func New

func New(flgConfigPath string) (*Config, error)

func (*Config) Save

func (c *Config) Save() error

type ForecastProviders

type ForecastProviders struct {
	OpenWeather openweather.Config `json:"openweather,omitempty"`
	Met         met.Config         `json:"met,omitempty"`
}

type GeocodeProviders

type GeocodeProviders struct {
	Google        google.Config        `json:"google,omitempty"`
	IPGeolocation ipgeolocation.Config `json:"ipgeolocation,omitempty"`
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL