conf

package
v0.0.6 Latest Latest
Warning

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

Go to latest
Published: Dec 4, 2023 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	Ver = "x.x.x"

	SrvCTL = len(os.Args) > 1 && (os.Args[1] == "install" || os.Args[1] == "uninstall" || os.Args[1] == "start")
)
View Source
var (
	EnvPath string

	IdeDebugging bool
	Testing      bool
)
View Source
var BgmiLogger *eslog.EnhanceLogger

Functions

This section is empty.

Types

type Environment

type Environment struct {
	Port            int    `yaml:"port"`
	SubjPath        string `yaml:"path"`
	DropOnDuplicate bool   `yaml:"drop-duplicate"`
	RssFilter       struct {
		Contain   []string `yaml:"contain"`
		Exclusion []string `yaml:"exclusion"`
	} `yaml:"rss-filter"`
	Crawl struct {
		Proxies []string `yaml:"proxies"`
	} `yaml:"crawl"`
	Qbt struct {
		Url             string `yaml:"url"`
		Username        string `yaml:"username"`
		Password        string `yaml:"password"`
		LocalConnect    bool   `yaml:"localed"`
		Timeout         int    `yaml:"timeout"`
		TrackerProvider string `yaml:"tracker-provider"`
		Proxy           struct {
			Addr     string `yaml:"address"`
			Type     string `yaml:"type"`
			Username string `yaml:"username"`
			Password string `yaml:"password"`
			Peer     bool   `yaml:"peer"`
			TorrOnly bool   `yaml:"torrent-only"`
			Hslookup bool   `yaml:"host-lookup"`
		} `yaml:"proxy"`
	} `yaml:"qbittorrent"`
	Pusher struct {
		Email struct {
			Host         string `yaml:"host"`
			Port         int    `yaml:"port"`
			Username     string `yaml:"username"`
			Password     string `yaml:"password"`
			TemplatePath string `yaml:"template"`
			SkipSSL      bool   `yaml:"skipssl"`
		} `yaml:"email"`
	} `yaml:"push"`
	BgmiLog bool `yaml:"bangumi-log"`
}
var Env Environment

func (*Environment) EmailPrint

func (env *Environment) EmailPrint()

func (*Environment) EnabledFilter

func (env *Environment) EnabledFilter() bool

func (*Environment) Print

func (env *Environment) Print()

Jump to

Keyboard shortcuts

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