contribcmd

package
v0.0.32 Latest Latest
Warning

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

Go to latest
Published: Oct 15, 2021 License: Apache-2.0 Imports: 17 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ContribCmd = &cobra.Command{
	Use:   "contributor",
	Short: "Manage repository contributors",
	Long:  ``,
	Run: func(cmd *cobra.Command, args []string) {
		cmd.Help()
	},
}

ContribCmd represents the contributor command

Functions

func AddCmd

func AddCmd(cfg *config.AppConfig, args *AddArgs) error

AddCmd creates a proposal transaction to add contributors to a repository

Types

type AddArgs

type AddArgs struct {

	// Name is the name of the repository where the contributors will be added to.
	Name string

	// PushKeys are a list of push keys to add as contributors
	PushKeys []string

	// PropID is the unique proposal ID
	PropID string

	// FeeCap is the contributors' fee cap
	FeeCap float64

	// FeeMode is the contributors' fee mode
	FeeMode int

	// Value is the proposal fee
	Value float64

	// Policies include policies specific to the contributor(s)
	Policies []*state.ContributorPolicy

	// Namespace adds the contributor(s) as namespace-level contributor(s)
	Namespace string

	// NamespaceOnly adds the contributor(s) only as namespace-level contributor(s)
	NamespaceOnly string

	// Nonce is the next nonce of the signing key's account
	Nonce uint64

	// Fee is the transaction fee to be paid by the signing key
	Fee float64

	// SigningKey is the account whose key will be used to sign the transaction.
	SigningKey string

	// AccountPass is the passphrase for unlocking the signing key.
	SigningKeyPass string

	// RpcClient is the RPC client
	RPCClient types.Client

	// KeyUnlocker is a function for getting and unlocking a push key from keystore.
	KeyUnlocker common.UnlockKeyFunc

	// GetNextNonce is a function for getting the next nonce of an account
	GetNextNonce api.NextNonceGetter

	// CreateRepo is a function for generating a transaction for creating a repository
	AddRepoContributors api.RepoContributorsAdder

	// ShowTxStatusTracker is a function tracking and displaying tx status
	ShowTxStatusTracker common.TxStatusTrackerFunc

	Stdout io.Writer
}

AddArgs contains arguments for AddCmd.

Jump to

Keyboard shortcuts

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