config

package
v0.0.3 Latest Latest
Warning

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

Go to latest
Published: Jul 12, 2023 License: Apache-2.0 Imports: 2 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 {
	Server   Server
	Weather  Weather
	Sentence Sentence
}

Config ...

func Load

func Load(path string) (*Config, error)

Load ...

type Sentence

type Sentence struct {
	ShanBayURL  string        `yaml:"shanbay_url" mapstructure:"shanbay"`
	ICiBaURL    string        `yaml:"iciba_url" mapstructure:"iciba"`
	ShaDiaoHost string        `yaml:"shadiao_host" mapstructure:"shadiao"`
	Timeout     time.Duration `yaml:"timeout"`
}

Sentence ...

type Server

type Server struct {
	Phone string `yaml:"phone"`
	Title string `yaml:"title"`
	End   string `yaml:"end"`
	Form  string `yaml:"form"`
}

Server ...

type Weather

type Weather struct {
	Host     string        `yaml:"host"`
	Token    string        `yaml:"token"`
	Version  string        `yaml:"version"`
	Location string        `yaml:"location"`
	Timeout  time.Duration `yaml:"timeout"`
}

Weather ...

Jump to

Keyboard shortcuts

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