config

package
v0.0.0-...-dd3c66b Latest Latest
Warning

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

Go to latest
Published: Dec 23, 2024 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Load

func Load(file string, c *Config) error

Load 加载配置

func Unmarshal

func Unmarshal(c *Config) error

Types

type Config

type Config struct {
	Database db.Config     `mapstructure:"database"`
	Log      zap.Config    `mapstructure:"log"`
	Redis    redis.Config  `mapstructure:"redis"`
	Crawler  CrawlerConfig `mapstructure:"crawler"`
}

Config 配置信息

type CrawlerConfig

type CrawlerConfig struct {
	TableArticles string `mapstructure:"table-articles"`
	Mark          string `mapstructure:"mark"`
	MarkEnable    bool   `mapstructure:"mark-enable"`
}

Jump to

Keyboard shortcuts

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