config

package
v0.0.0-...-2bc12df Latest Latest
Warning

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

Go to latest
Published: Mar 18, 2021 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Overview

Package config implements configuration for the wash executable using https://github.com/spf13/viper.

Index

Constants

View Source
const (
	SocketKey   = "socket"
	EmbeddedKey = "embedded"
)

Contains all the keys for Wash's shared config

Variables

View Source
var Embedded bool
View Source
var Socket string

Socket is the path to the Wash server's UNIX socket

Functions

func DefaultFile

func DefaultFile() string

DefaultFile returns the default config file's path

func DefaultFileAbsPath

func DefaultFileAbsPath() string

DefaultFileAbsPath returns the default config file's absolute path

func Init

func Init() error

Init initializes the config package. It loads Wash's defaults and sets up viper

func ReadFrom

func ReadFrom(file string) error

ReadFrom reads the config from the specified file. If file == DefaultFile(), then ReadFrom wil not return an error if file does not exist.

Types

This section is empty.

Jump to

Keyboard shortcuts

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