global

package
v1.5.0 Latest Latest
Warning

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

Go to latest
Published: May 6, 2020 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

View Source
const (
	DefaultRuntimeDir = "~/.genesis"
	DefaultApiAddr    = "127.0.0.1:9011"
	DefaultCrypto     = crypto.CryptoTypeZhongAn

	DefaultApp = "evm"
)

Variables

This section is empty.

Functions

func CheckAndReadRuntimeConfig

func CheckAndReadRuntimeConfig(runtimeDir string) (err error)

func CheckAppName

func CheckAppName(appName string) bool

func CheckCryptoType

func CheckCryptoType(ctype string) bool

func CheckInitialized

func CheckInitialized(path string) error

func ConfigIsInitialized

func ConfigIsInitialized(cfgPath string) bool

func GConf

func GConf() *viper.Viper

func GenConf

func GenConf() *viper.Viper

func ReadRuntime

func ReadRuntime() string

Types

type GlobalFlags

type GlobalFlags struct {
	Debug      bool
	RuntimeDir string
	LogDir     string
	ApiAddr    string
}

func GFlags

func GFlags() *GlobalFlags

type NoRuntimeError

type NoRuntimeError struct {
	Path string
}

func (NoRuntimeError) Error

func (err NoRuntimeError) Error() string

Jump to

Keyboard shortcuts

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