This project aims to reference the genesis block of the Ethereum blockchain in JSON format for the following networks:
Below the Go
code used to dump the MainNet genesis block in JSON format:
package main
import "io/ioutil"
import "github.com/ethereum/go-ethereum/core"
func check(e error) {
if e != nil {
panic(e)
}
}
func main() {
genesisBlock := core.DefaultGenesisBlock()
bytes, _ := genesisBlock.MarshalJSON()
err := ioutil.WriteFile("./mainnet.json", bytes, 0644)
check(err)
}
Issues can be reported at https://github.com/odaceo/ethereum-genesis-block/issues
The source code is available at https://github.com/odaceo/ethereum-genesis-block
All the source code is distributed under ASL 2.0.
© 2020 Odaceo. All rights reserved.