configs

package
v0.6.3 Latest Latest
Warning

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

Go to latest
Published: Jan 13, 2023 License: BSD-3-Clause Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Secret = ""

Functions

func ResetAPIConfig added in v0.1.0

func ResetAPIConfig() error

ResetAPIConfig 重置配置

func WritePlusConfig added in v0.2.8

func WritePlusConfig(config *PlusConfig) error

Types

type APIConfig

type APIConfig struct {
	RPC struct {
		Endpoints     []string `yaml:"endpoints"`
		DisableUpdate bool     `yaml:"disableUpdate"`
	} `yaml:"rpc"`
	NodeId string `yaml:"nodeId"`
	Secret string `yaml:"secret"`
}

APIConfig API配置

func LoadAPIConfig

func LoadAPIConfig() (*APIConfig, error)

LoadAPIConfig 加载API配置

func (*APIConfig) WriteFile

func (this *APIConfig) WriteFile(path string) error

WriteFile 写入API配置

type PlusConfig added in v0.2.8

type PlusConfig struct {
	IsPlus     bool     `json:"isPlus"`
	Components []string `json:"components"`
	DayTo      string   `json:"dayTo"`
}

func ReadPlusConfig added in v0.2.8

func ReadPlusConfig() *PlusConfig

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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