Help us shape the future of Go! Take the 2026 Go Developer Survey

list

package
v0.1.121 Latest Latest
Warning

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

Go to latest
Published: Sep 21, 2026 License: AGPL-3.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ListCmd = &cobra.Command{
	Use:     "list",
	Short:   "List the keys in the keyring / keystore.",
	Long:    usage,
	Args:    cobra.NoArgs,
	PreRunE: signer.SanityCheck,
	RunE: func(cmd *cobra.Command, args []string) error {
		opts := signer.InputOpts
		if opts.Keystore != "" {
			ks := keystore.NewKeyStore(opts.Keystore, keystore.StandardScryptN, keystore.StandardScryptP)
			accounts := ks.Accounts()
			for idx, a := range accounts {
				log.Info().Str("account", a.Address.String()).Int("index", idx).Msg("Account")
			}
			return nil
		}
		if opts.KMS == "GCP" {
			gcpKMS := signer.GCPKMS{}
			return gcpKMS.ListKeyRingKeys(cmd.Context())
		}
		return fmt.Errorf("unable to list accounts")
	},
}

Functions

This section is empty.

Types

This section is empty.

Jump to

Keyboard shortcuts

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