fix(config): add config loading functions and tests, also fix config issues
This commit is contained in:
parent
67da1ea0eb
commit
32a003d789
11 changed files with 42 additions and 69 deletions
|
@ -31,20 +31,20 @@ type ISiteStore interface {
|
|||
}
|
||||
|
||||
type ClientConfig struct {
|
||||
SiteName string `json:"siteName"`
|
||||
SiteDesc string `json:"siteDesc"`
|
||||
Bg *BgConfig `json:"bg"`
|
||||
SiteName string `json:"siteName" yaml:"siteName"`
|
||||
SiteDesc string `json:"siteDesc" yaml:"siteDesc"`
|
||||
Bg *BgConfig `json:"bg" yaml:"bg"`
|
||||
}
|
||||
|
||||
type BgConfig struct {
|
||||
Url string `json:"url"`
|
||||
Repeat string `json:"repeat"`
|
||||
Position string `json:"position"`
|
||||
Align string `json:"align"`
|
||||
Url string `json:"url" yaml:"url"`
|
||||
Repeat string `json:"repeat" yaml:"repeat"`
|
||||
Position string `json:"position" yaml:"position"`
|
||||
Align string `json:"align" yaml:"align"`
|
||||
}
|
||||
|
||||
type SiteConfig struct {
|
||||
ClientCfg *ClientConfig `json:"clientCfg"`
|
||||
ClientCfg *ClientConfig `json:"clientCfg" yaml:"clientCfg"`
|
||||
}
|
||||
|
||||
type SiteStore struct {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue