flags

package
v0.2103.3 Latest Latest
Warning

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

Go to latest
Published: Oct 21, 2021 License: Apache-2.0 Imports: 2 Imported by: 4

Documentation

Overview

Package flags implements common flags used across multiple commands and backends.

Index

Constants

View Source
const (
	// CfgDebugDontBlameOasis is the flag used to opt-in to unsafe/debug/test
	// behavior.
	CfgDebugDontBlameOasis = "debug.dont_blame_oasis"
	// CfgDebugTestEntity is the command line flag to enable the debug test
	// entity.
	CfgDebugTestEntity = "debug.test_entity"
	// CfgGenesisFile is the flag used to specify a genesis file.
	CfgGenesisFile = "genesis.file"
	// CfgConsensusValidator is the flag used to opt-in to being a validator.
	CfgConsensusValidator = "consensus.validator"

	// CfgDryRun is the flag used to specify a dry-run of an operation.
	CfgDryRun = "dry_run"

	// CfgAssumeYes is the flag used to denote to answer all user prompts with
	// yes.
	CfgAssumeYes = "assume_yes"
)

Variables

View Source
var (
	// VerboseFlags has the verbose flag.
	VerboseFlags = flag.NewFlagSet("", flag.ContinueOnError)
	// ForceFlags has the force flag.
	ForceFlags = flag.NewFlagSet("", flag.ContinueOnError)
	// DebugTestEntityFlags has the test entity enable flag.
	DebugTestEntityFlags = flag.NewFlagSet("", flag.ContinueOnError)

	// GenesisFileFlags has the genesis file flag.
	GenesisFileFlags = flag.NewFlagSet("", flag.ContinueOnError)

	// ConsensusValidatorFlag has the consensus validator flag.
	ConsensusValidatorFlag = flag.NewFlagSet("", flag.ContinueOnError)
	// DebugDontBlameOasisFlag has the "don't blame oasis" flag.
	DebugDontBlameOasisFlag = flag.NewFlagSet("", flag.ContinueOnError)

	// DryRunFlag has the dry-run flag.
	DryRunFlag = flag.NewFlagSet("", flag.ContinueOnError)

	// AssumeYesFlag has the assume yes flag.
	AssumeYesFlag = flag.NewFlagSet("", flag.ContinueOnError)
)

Functions

func AssumeYes

func AssumeYes() bool

AssumeYes returns true iff the assume yes flag is set.

func ConsensusValidator

func ConsensusValidator() bool

ConsensusValidator returns true iff the node is opting in to be a consensus validator.

func DebugDontBlameOasis

func DebugDontBlameOasis() bool

DebugDontBlameOasis returns true iff the "don't blame oasis" flag is set.

func DebugTestEntity

func DebugTestEntity() bool

DebugTestEntity returns true iff the test entity enable flag is set.

func DryRun

func DryRun() bool

DryRun returns true iff the dry-run flag is set.

func Force

func Force() bool

Force returns true iff the force flag is set.

func GenesisFile

func GenesisFile() string

GenesisFile returns the set genesis file.

func Verbose

func Verbose() bool

Verbose returns true iff the verbose flag is set.

Types

This section is empty.

Jump to

Keyboard shortcuts

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