cmd

package
v28.0.0 Latest Latest
Warning

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

Go to latest
Published: Feb 20, 2025 License: Apache-2.0 Imports: 59 Imported by: 0

Documentation

Index

Constants

View Source
const (
	FlagMinimumStakeAmount = "minimum-stake-amount"
)

Variables

View Source
var (
	// Bech32Prefix defines the Bech32 prefix of an account's address
	Bech32Prefix = "juno"
	// Bech32PrefixAccAddr defines the Bech32 prefix of an account's address
	Bech32PrefixAccAddr = Bech32Prefix
	// Bech32PrefixAccPub defines the Bech32 prefix of an account's public key
	Bech32PrefixAccPub = Bech32Prefix + sdk.PrefixPublic
	// Bech32PrefixValAddr defines the Bech32 prefix of a validator's operator address
	Bech32PrefixValAddr = Bech32Prefix + sdk.PrefixValidator + sdk.PrefixOperator
	// Bech32PrefixValPub defines the Bech32 prefix of a validator's operator public key
	Bech32PrefixValPub = Bech32Prefix + sdk.PrefixValidator + sdk.PrefixOperator + sdk.PrefixPublic
	// Bech32PrefixConsAddr defines the Bech32 prefix of a consensus node address
	Bech32PrefixConsAddr = Bech32Prefix + sdk.PrefixValidator + sdk.PrefixConsensus
	// Bech32PrefixConsPub defines the Bech32 prefix of a consensus node public key
	Bech32PrefixConsPub = Bech32Prefix + sdk.PrefixValidator + sdk.PrefixConsensus + sdk.PrefixPublic
)
View Source
var ResetAppCmd = &cobra.Command{
	Use:   "app",
	Short: "Reset App files",
	RunE: func(cmd *cobra.Command, _ []string) (err error) {
		clientCtx := client.GetClientContextFromCmd(cmd)
		serverCtx := server.GetServerContextFromCmd(cmd)
		config := serverCtx.Config

		config.SetRoot(clientCtx.HomeDir)

		return resetApp(config.DBDir())
	},
}

ResetAppCmd removes the database of the specified Comet core instance.

View Source
var ResetWasmCmd = &cobra.Command{
	Use:   "wasm",
	Short: "Reset WASM files",
	RunE: func(cmd *cobra.Command, _ []string) (err error) {
		clientCtx := client.GetClientContextFromCmd(cmd)
		serverCtx := server.GetServerContextFromCmd(cmd)
		config := serverCtx.Config

		config.SetRoot(clientCtx.HomeDir)

		return resetWasm(config.DBDir())
	},
}

ResetWasmCmd removes the database of the specified Comet core instance.

Functions

func AddGenesisIcaCmd

func AddGenesisIcaCmd(defaultNodeHome string) *cobra.Command

AddGenesisIcaCmd returns add-genesis-account cobra Command.

func AddrCmd

func AddrCmd() *cobra.Command

func CodecCmd

func CodecCmd() *cobra.Command

CodecCmd creates and returns a new codec debug cmd.

func ConvertBech32Cmd

func ConvertBech32Cmd() *cobra.Command

get cmd to convert any bech32 address to a juno prefix.

func DebugCmd

func DebugCmd() *cobra.Command

Cmd creates a main CLI command

func ExportDeriveBalancesCmd

func ExportDeriveBalancesCmd() *cobra.Command

ExportDeriveBalancesCmd generates a snapshot.json from a provided exported genesis.json.

func NewRootCmd

func NewRootCmd() *cobra.Command

NewRootCmd creates a new root command for junod. It is called once in the main function.

func PrefixesCmd

func PrefixesCmd() *cobra.Command

func PubkeyCmd

func PubkeyCmd() *cobra.Command

func RawBytesCmd

func RawBytesCmd() *cobra.Command

func ResetCmd

func ResetCmd() *cobra.Command

Cmd creates a main CLI command

func SetCustomEnvVariablesFromClientToml

func SetCustomEnvVariablesFromClientToml(ctx client.Context)

Reads the custom extra values in the config.toml file if set. If they are, then use them.

func StakedToCSVCmd

func StakedToCSVCmd() *cobra.Command

StakedToCSVCmd generates a airdrop.csv from a provided exported balances.json.

Types

type DeriveSnapshot

type DeriveSnapshot struct {
	NumberAccounts uint64                    `json:"num_accounts"`
	Accounts       map[string]DerivedAccount `json:"accounts"`
}

type DerivedAccount

type DerivedAccount struct {
	Address        string      `json:"address"`
	LiquidBalances sdk.Coins   `json:"liquid_balance"`
	Staked         sdkmath.Int `json:"staked"`
	UnbondingStake sdkmath.Int `json:"unbonding_stake"`
	Bonded         sdk.Coins   `json:"bonded"`
	TotalBalances  sdk.Coins   `json:"total_balances"`
}

DerivedAccount provide fields of snapshot per account It is the simplified struct we are presenting in this 'balances from state export' snapshot for people.

Jump to

Keyboard shortcuts

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