diff --git a/client/commands/seeds/export.go b/client/commands/commits/export.go similarity index 66% rename from client/commands/seeds/export.go rename to client/commands/commits/export.go index 0eeaed01f..c27826fa7 100644 --- a/client/commands/seeds/export.go +++ b/client/commands/commits/export.go @@ -1,4 +1,4 @@ -package seeds +package commits import ( "github.com/pkg/errors" @@ -12,21 +12,21 @@ import ( var exportCmd = &cobra.Command{ Use: "export ", - Short: "Export selected seeds to given file", - Long: `Exports the most recent seed to a binary file. + Short: "Export selected commits to given file", + Long: `Exports the most recent commit to a binary file. If desired, you can select by an older height or validator hash. `, - RunE: commands.RequireInit(exportSeed), + RunE: commands.RequireInit(exportCommit), SilenceUsage: true, } func init() { - exportCmd.Flags().Int(heightFlag, 0, "Show the seed with closest height to this") - exportCmd.Flags().String(hashFlag, "", "Show the seed matching the validator hash") + exportCmd.Flags().Int(heightFlag, 0, "Show the commit with closest height to this") + exportCmd.Flags().String(hashFlag, "", "Show the commit matching the validator hash") RootCmd.AddCommand(exportCmd) } -func exportSeed(cmd *cobra.Command, args []string) error { +func exportCommit(cmd *cobra.Command, args []string) error { if len(args) != 1 || len(args[0]) == 0 { return errors.New("You must provide a filepath to output") } diff --git a/client/commands/seeds/import.go b/client/commands/commits/import.go similarity index 80% rename from client/commands/seeds/import.go rename to client/commands/commits/import.go index d115463c8..936d25b06 100644 --- a/client/commands/seeds/import.go +++ b/client/commands/commits/import.go @@ -1,4 +1,4 @@ -package seeds +package commits import ( "fmt" @@ -18,9 +18,9 @@ const ( var importCmd = &cobra.Command{ Use: "import ", - Short: "Imports a new seed from the given file", - Long: `Validate this file and update to the given seed if secure.`, - RunE: commands.RequireInit(importSeed), + Short: "Imports a new commit from the given file", + Long: `Validate this file and update to the given commit if secure.`, + RunE: commands.RequireInit(importCommit), SilenceUsage: true, } @@ -29,7 +29,7 @@ func init() { RootCmd.AddCommand(importCmd) } -func importSeed(cmd *cobra.Command, args []string) error { +func importCommit(cmd *cobra.Command, args []string) error { if len(args) != 1 || len(args[0]) == 0 { return errors.New("You must provide an input file") } diff --git a/client/commands/seeds/root.go b/client/commands/commits/root.go similarity index 52% rename from client/commands/seeds/root.go rename to client/commands/commits/root.go index b4fc9d66f..513d86873 100644 --- a/client/commands/seeds/root.go +++ b/client/commands/commits/root.go @@ -1,15 +1,15 @@ -package seeds +package commits import "github.com/spf13/cobra" // RootCmd represents the base command when called without any subcommands var RootCmd = &cobra.Command{ - Use: "seeds", - Short: "Verify seeds from your local store", - Long: `Seeds allows you to inspect and update the validator set for the chain. + Use: "commits", + Short: "Verify commits from your local store", + Long: `Commits allows you to inspect and update the validator set for the chain. Since all security in a PoS system is based on having the correct validator -set, it is important to inspect the seeds to maintain the security, which +set, it is important to inspect the commits to maintain the security, which is used to verify all header and merkle proofs. `, } diff --git a/client/commands/seeds/show.go b/client/commands/commits/show.go similarity index 85% rename from client/commands/seeds/show.go rename to client/commands/commits/show.go index 953548a1a..e9cc6ed28 100644 --- a/client/commands/seeds/show.go +++ b/client/commands/commits/show.go @@ -1,4 +1,4 @@ -package seeds +package commits import ( "encoding/hex" @@ -31,9 +31,9 @@ If desired, you can select by height, validator hash, or a file. } func init() { - showCmd.Flags().Int(heightFlag, 0, "Show the seed with closest height to this") - showCmd.Flags().String(hashFlag, "", "Show the seed matching the validator hash") - showCmd.Flags().String(fileFlag, "", "Show the seed stored in the given file") + showCmd.Flags().Int(heightFlag, 0, "Show the commit with closest height to this") + showCmd.Flags().String(hashFlag, "", "Show the commit matching the validator hash") + showCmd.Flags().String(fileFlag, "", "Show the commit stored in the given file") RootCmd.AddCommand(showCmd) } diff --git a/client/commands/seeds/update.go b/client/commands/commits/update.go similarity index 98% rename from client/commands/seeds/update.go rename to client/commands/commits/update.go index 4d99c59bd..c42144b61 100644 --- a/client/commands/seeds/update.go +++ b/client/commands/commits/update.go @@ -1,4 +1,4 @@ -package seeds +package commits import ( "fmt" diff --git a/examples/basecoin/cmd/basecli/main.go b/examples/basecoin/cmd/basecli/main.go index 6145e8642..107890a75 100644 --- a/examples/basecoin/cmd/basecli/main.go +++ b/examples/basecoin/cmd/basecli/main.go @@ -9,11 +9,11 @@ import ( "github.com/cosmos/cosmos-sdk/client/commands" "github.com/cosmos/cosmos-sdk/client/commands/auto" + "github.com/cosmos/cosmos-sdk/client/commands/commits" "github.com/cosmos/cosmos-sdk/client/commands/keys" "github.com/cosmos/cosmos-sdk/client/commands/proxy" "github.com/cosmos/cosmos-sdk/client/commands/query" rpccmd "github.com/cosmos/cosmos-sdk/client/commands/rpc" - "github.com/cosmos/cosmos-sdk/client/commands/seeds" txcmd "github.com/cosmos/cosmos-sdk/client/commands/txs" authcmd "github.com/cosmos/cosmos-sdk/modules/auth/commands" basecmd "github.com/cosmos/cosmos-sdk/modules/base/commands" @@ -77,7 +77,7 @@ func main() { commands.InitCmd, commands.ResetCmd, keys.RootCmd, - seeds.RootCmd, + commits.RootCmd, rpccmd.RootCmd, query.RootCmd, txcmd.RootCmd, diff --git a/examples/counter/cmd/countercli/main.go b/examples/counter/cmd/countercli/main.go index 0e7c251e6..d2845aefc 100644 --- a/examples/counter/cmd/countercli/main.go +++ b/examples/counter/cmd/countercli/main.go @@ -8,10 +8,10 @@ import ( "github.com/tendermint/tmlibs/cli" "github.com/cosmos/cosmos-sdk/client/commands" + "github.com/cosmos/cosmos-sdk/client/commands/commits" "github.com/cosmos/cosmos-sdk/client/commands/keys" "github.com/cosmos/cosmos-sdk/client/commands/proxy" "github.com/cosmos/cosmos-sdk/client/commands/query" - "github.com/cosmos/cosmos-sdk/client/commands/seeds" txcmd "github.com/cosmos/cosmos-sdk/client/commands/txs" bcount "github.com/cosmos/cosmos-sdk/examples/counter/cmd/countercli/commands" @@ -74,7 +74,7 @@ func main() { commands.ResetCmd, commands.VersionCmd, keys.RootCmd, - seeds.RootCmd, + commits.RootCmd, query.RootCmd, txcmd.RootCmd, proxy.RootCmd, diff --git a/examples/eyes/cmd/eyescli/main.go b/examples/eyes/cmd/eyescli/main.go index 374e59d07..d23a0e8dc 100644 --- a/examples/eyes/cmd/eyescli/main.go +++ b/examples/eyes/cmd/eyescli/main.go @@ -9,9 +9,9 @@ import ( "github.com/cosmos/cosmos-sdk/client/commands" "github.com/cosmos/cosmos-sdk/client/commands/auto" + "github.com/cosmos/cosmos-sdk/client/commands/commits" "github.com/cosmos/cosmos-sdk/client/commands/query" rpccmd "github.com/cosmos/cosmos-sdk/client/commands/rpc" - "github.com/cosmos/cosmos-sdk/client/commands/seeds" txcmd "github.com/cosmos/cosmos-sdk/client/commands/txs" eyescmd "github.com/cosmos/cosmos-sdk/modules/eyes/commands" ) @@ -50,7 +50,7 @@ func main() { // we use out own init command to not require address arg commands.InitCmd, commands.ResetCmd, - seeds.RootCmd, + commits.RootCmd, rpccmd.RootCmd, query.RootCmd, txcmd.RootCmd,