You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

23 lines
399 B

10 years ago
10 years ago
  1. package main
  2. import (
  3. "fmt"
  4. "github.com/tendermint/tendermint/config"
  5. "github.com/tendermint/tendermint/state"
  6. )
  7. func gen_validator() {
  8. privValidator := state.GenPrivValidator()
  9. privValidatorJSONBytes := privValidator.JSONBytes()
  10. fmt.Printf(`Generated a new validator!
  11. Paste the following JSON into your %v file
  12. %v
  13. `,
  14. config.PrivValidatorFile(),
  15. string(privValidatorJSONBytes),
  16. )
  17. }