config

package
v0.1.1 Latest Latest
Warning

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

Go to latest
Published: Oct 28, 2020 License: GPL-3.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Parse

func Parse(path string) error

Parse Config file

func ReadFile

func ReadFile(path string) ([]byte, error)

从本地文件或者http链接读取配置文件内容

Types

type ConfigOptions

type ConfigOptions struct {
	ServerUrl string `json:"server_url" yaml:"server_url"`
	Request   string `json:"request" yaml:"request"'`
	Domain    string `json:"domain" yaml:"domain"`
	Port      string `json:"port" yaml:"port"`
}

ConfigOptions is a struct that represents config files

var Config ConfigOptions

Jump to

Keyboard shortcuts

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