cmd

package
v1.1.3 Latest Latest
Warning

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

Go to latest
Published: Jan 22, 2022 License: Apache-2.0 Imports: 45 Imported by: 0

Documentation

Index

Constants

View Source
const (
	HumanCoinUnit       = "stars"
	BaseCoinUnit        = "ustars"
	StarsExponent       = 6
	Bech32PrefixAccAddr = "stars"
)
View Source
const (
	// FlagOverwrite defines a flag to overwrite an existing genesis JSON file.
	FlagOverwrite = "overwrite"

	// FlagSeed defines a flag to initialize the private validator key from a specific seed.
	FlagRecover = "recover"
)

Variables

This section is empty.

Functions

func InitCmd

func InitCmd(mbm module.BasicManager, defaultNodeHome string) *cobra.Command

InitCmd returns a command that initializes all files needed for Tendermint and the respective application.

func InitTestnet

func InitTestnet(
	clientCtx client.Context,
	cmd *cobra.Command,
	nodeConfig *tmconfig.Config,
	mbm module.BasicManager,
	genBalIterator banktypes.GenesisBalancesIterator,
	outputDir,
	chainID,
	minGasPrices,
	nodeDirPrefix,
	nodeDaemonHome,
	startingIPAddress,
	keyringBackend,
	algoStr string,
	numValidators int,
) error

Initialize the testnet

func PrepareGenesis added in v0.8.0

func PrepareGenesis(
	clientCtx client.Context,
	appState map[string]json.RawMessage,
	genDoc *tmtypes.GenesisDoc,
	genesisParams GenesisParams,
	chainID string,
	snapshot Snapshot,
) (map[string]json.RawMessage, *tmtypes.GenesisDoc, error)

fill with data

func PrepareGenesisCmd added in v0.8.0

func PrepareGenesisCmd(defaultNodeHome string, mbm module.BasicManager) *cobra.Command

func TestnetCmd added in v1.0.0

func TestnetCmd(mbm module.BasicManager) *cobra.Command

get cmd to initialize all files for tendermint testnet and application

Types

type GenesisParams added in v0.8.0

type GenesisParams struct {
	AirdropSupply sdk.Int

	StrategicReserveAccounts []banktypes.Balance

	ConsensusParams *tmproto.ConsensusParams

	GenesisTime         time.Time
	NativeCoinMetadatas []banktypes.Metadata

	StakingParams      stakingtypes.Params
	DistributionParams distributiontypes.Params
	GovParams          govtypes.Params

	CrisisConstantFee sdk.Coin

	SlashingParams slashingtypes.Params

	AllocParams alloctypes.Params
	ClaimParams claimtypes.Params
	MintParams  minttypes.Params
}

func DevnetGenesisParams added in v1.0.0

func DevnetGenesisParams() GenesisParams

func MainnetGenesisParams added in v0.8.0

func MainnetGenesisParams() GenesisParams

params only

func TestnetGenesisParams added in v0.8.0

func TestnetGenesisParams() GenesisParams

params only

type Snapshot added in v0.8.0

type Snapshot struct {
	TotalStarsAirdropAmount sdk.Int                    `json:"total_stars_amount"`
	Accounts                map[string]SnapshotAccount `json:"accounts"`
}

type SnapshotAccount added in v0.8.0

type SnapshotAccount struct {
	AtomAddress              string  `json:"atom_address"`
	OsmoAddress              string  `json:"osmo_address"`
	RegenAddress             string  `json:"regen_address"`
	StargazeHubDelegator     bool    `json:"sg_hub_delegator"`
	StargazeOsmosisDelegator bool    `json:"sg_osmosis_delegator"`
	StargazeRegenDelegator   bool    `json:"sg_regen_delegator"`
	AtomStaker               bool    `json:"atom_staker"`
	OsmoStaker               bool    `json:"osmo_staker"`
	OsmosisLiquidityProvider bool    `json:"osmosis_lp"`
	AirdropAmount            sdk.Int `json:"airdrop_amount"`
}

type TestnetNode

type TestnetNode struct {
	Name             string
	OutsidePortRange string
	InsidePortRange  string
	APIPort          string
	GRPCPort         string
}

TestnetNode holds configuration for nodes

Jump to

Keyboard shortcuts

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