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.

56 lines
1.4 KiB

6 years ago
6 years ago
  1. package version
  2. var (
  3. // GitCommit is the current HEAD set using ldflags.
  4. GitCommit string
  5. // Version is the built softwares version.
  6. Version string = TMCoreSemVer
  7. )
  8. func init() {
  9. if GitCommit != "" {
  10. Version += "-" + GitCommit
  11. }
  12. }
  13. const (
  14. // TMCoreSemVer is the current version of Tendermint Core.
  15. // It's the Semantic Version of the software.
  16. // Must be a string because scripts like dist.sh read this file.
  17. TMCoreSemVer = "0.25.0"
  18. // ABCISemVer is the semantic version of the ABCI library
  19. ABCISemVer = "0.14.0"
  20. ABCIVersion = ABCISemVer
  21. )
  22. // Protocol is used for implementation agnostic versioning.
  23. type Protocol uint64
  24. var (
  25. // P2PProtocol versions all p2p behaviour and msgs.
  26. P2PProtocol Protocol = 4
  27. // BlockProtocol versions all block data structures and processing.
  28. BlockProtocol Protocol = 7
  29. )
  30. //------------------------------------------------------------------------
  31. // Version types
  32. // App includes the protocol and software version for the application.
  33. // This information is included in ResponseInfo. The App.Protocol can be
  34. // updated in ResponseEndBlock.
  35. type App struct {
  36. Protocol Protocol `json:"protocol"`
  37. Software string `json:"software"`
  38. }
  39. // Consensus captures the consensus rules for processing a block in the blockchain,
  40. // including all blockchain data structures and the rules of the application's
  41. // state transition machine.
  42. type Consensus struct {
  43. Block Protocol `json:"block"`
  44. App Protocol `json:"app"`
  45. }