config

package
v0.0.0-...-3832f50 Latest Latest
Warning

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

Go to latest
Published: Mar 24, 2017 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CreateBaseDir

func CreateBaseDir() error

CreateBaseDir creates the base directory in the configuration

func Initialize

func Initialize()

Initialize our configuration by binding with viper

func Print

func Print()

Print dumps the current configuration to stdout

func PrivateKey

func PrivateKey() string

PrivateKey returns the absolute path to the private key

func PublicKey

func PublicKey() string

PublicKey returns the absolute path to the public key

func UpdateLogging

func UpdateLogging()

UpdateLogging modifies default logging based on configuration

func UserHomeDir

func UserHomeDir() string

UserHomeDir returns the home directory for windows & *nix

Types

type LogSettings

type LogSettings struct {
	Level string `yaml:"level"`
}

LogSettings holds the settings for logging

type Settings

type Settings struct {
	BaseDir       string      `yaml:"baseDir"`
	EncryptMethod string      `yaml:"encryptMethod"`
	PublicKey     string      `yaml:"publicKey"`
	PrivateKey    string      `yaml:"privateKey"`
	Logging       LogSettings `yaml:"logging"`
}

Settings holds the global settings

Jump to

Keyboard shortcuts

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