config

package
v0.0.11 Latest Latest
Warning

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

Go to latest
Published: Oct 27, 2022 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Load

func Load(cfg interface{}, filename string) error

func Save

func Save(cfg interface{}, filename string) error

Types

type FileConfig

type FileConfig struct {
	BaseDir  string `json:"base_dir,omitempty"`
	FilePath string `json:"-"` //absolute path
}

func (*FileConfig) AbsBaseDir

func (c *FileConfig) AbsBaseDir() string

func (*FileConfig) ResolveAbsolute

func (c *FileConfig) ResolveAbsolute(targetPath string) string

func (*FileConfig) ResolveRelative

func (c *FileConfig) ResolveRelative(targetPath string) string

func (*FileConfig) SetFilePath

func (c *FileConfig) SetFilePath(targetPath string)

Jump to

Keyboard shortcuts

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