config

package
v0.0.0-...-1d9b62b Latest Latest
Warning

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

Go to latest
Published: Jan 7, 2023 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetConfig

func GetConfig(configPath string, config *Config) error

Types

type Config

type Config struct {
	PiAwareConfig struct {
		AircraftUrl string `yaml:"aircraft-url" env:"FA_AC_URL" env-default:"http://piaware:80/skyaware/data/aircraft.json"`
		ReceiverUrl string `yaml:"receiver-url" env:"FA_RCV_URL" env-defualt:"http://piaware:80/skyaware/data/receiver.json"`
	} `yaml:"piaware"`
	Display struct {
		Delay              int    `yaml:"delay" env:"FA_DISPLAY_DELAY" env-default:"5"`
		TransitionAltitude int    `yaml:"transAlt" env:"FA_TRANSALT" env-default:"19000"`
		UseFlightLevel     bool   `yaml:"useFL" env:"FA_USEFL" env-default:"true"`
		AltitudeUnits      string `yaml:"altUnits" env:"FA_ALTUOM" env-default:"FT"`
		SpeedUnits         string `yaml:"speedUnits" env:"FA_SPEEDUOM" env-default:"KN"`
		DistanceUnits      string `yaml:"distanceUnits" env:"FA_DISTUOM" env-default:"NM"`
	} `yaml:"display"`
}

Jump to

Keyboard shortcuts

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