config

package
v1.1.1 Latest Latest
Warning

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

Go to latest
Published: Oct 22, 2022 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

View Source
const CONFIG_YML = `` /* 1478-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"`
		TRASH_DIR string `yaml:"TRASH"`
		NEW_DIR   string `yaml:"NEW"`
	}
	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"`
		LEVEL string `yaml:"LEVEL"`
	}
	OPDS struct {
		PORT      int    `yaml:"PORT"`
		TITLE     string `yaml:"TITLE"`
		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