config

package
v1.0.3 Latest Latest
Warning

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

Go to latest
Published: Jul 23, 2022 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

View Source
const CONFIG_YML = `` /* 1174-byte string literal not displayed */

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	Library struct {
		STOCK_DIR string `yaml:"STOCK"`
		NEW_DIR   string `yaml:"NEW"`
		TRASH_DIR string `yaml:"TRASH"`
	}
	Database struct {
		DSN              string `yaml:"DSN"`
		INIT_SCRIPT      string `yaml:"INIT_SCRIPT"`
		DROP_SCRIPT      string `yaml:"DROP_SCRIPT"`
		POLL_DELAY       int    `yaml:"POLL_DELAY"`
		MAX_SCAN_THREADS int    `yaml:"MAX_SCAN_THREADS"`
	}
	Genres struct {
		TREE_FILE string `yaml:"TREE_FILE"`
	}
	Logs struct {
		OPDS  string `yaml:"OPDS"`
		SCAN  string `yaml:"SCAN"`
		DEBUG bool   `yaml:"DEBUG"`
	}
	OPDS struct {
		PORT      int `yaml:"PORT"`
		PAGE_SIZE int `yaml:"PAGE_SIZE"`
	}
	locales.Locales
}

See config.yml for comments about this struct

func LoadConfig

func LoadConfig() *Config

func (*Config) InitLogs added in v1.0.3

func (c *Config) InitLogs(needOpds bool) (stockLog, opdsLog *rlog.Log)

Jump to

Keyboard shortcuts

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