cmd

package
v0.12.0 Latest Latest
Warning

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

Go to latest
Published: Jun 19, 2023 License: MIT Imports: 23 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Pactus = ``

Functions

func CreateNode added in v0.10.0

func CreateNode(numValidators int, chain genesis.ChainType, workingDir string,
	mnemonic string, walletPassword string) (
	validatorAddrs []string, rewardAddrs []string, err error)

func FatalErrorCheck added in v0.10.0

func FatalErrorCheck(err error)

func PactusConfigPath

func PactusConfigPath(home string) string

func PactusDefaultWalletPath

func PactusDefaultWalletPath(home string) string

func PactusGenesisPath

func PactusGenesisPath(home string) string

func PactusHomeDir

func PactusHomeDir() string

func PrintErrorMsg

func PrintErrorMsg(format string, a ...interface{})

func PrintInfoMsg

func PrintInfoMsg(format string, a ...interface{})

func PrintInfoMsgBold added in v0.10.0

func PrintInfoMsgBold(format string, a ...interface{})

func PrintJSONData

func PrintJSONData(data []byte)

func PrintJSONObject

func PrintJSONObject(obj interface{})

func PrintLine

func PrintLine()

func PrintSuccessMsg

func PrintSuccessMsg(format string, a ...interface{})

func PrintWarnMsg

func PrintWarnMsg(format string, a ...interface{})

func PromptConfirm

func PromptConfirm(label string) bool

PromptConfirm prompts user to confirm the operation.

func PromptInput

func PromptInput(label string) string

PromptInput prompts for an input string.

func PromptInputWithRange added in v0.10.0

func PromptInputWithRange(label string, def, min, max int) int

PromptInputWithRange prompts the user for an input integer within a specified range.

func PromptInputWithSuggestion

func PromptInputWithSuggestion(label, suggestion string) string

PromptInputWithSuggestion prompts the user for an input string with a suggestion.

func PromptPassword

func PromptPassword(label string, confirmation bool) string

PromptPassword prompts the user for a password. Set confirmation to true to require the user to confirm the password.

func StartNode added in v0.11.0

func StartNode(workingDir string, passwordFetcher func(*wallet.Wallet) (string, bool)) (
	*node.Node, *wallet.Wallet, error)

func TrapSignal

func TrapSignal(cleanupFunc func())

TrapSignal traps SIGINT and SIGTERM and terminates the server correctly.

Types

This section is empty.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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