Skip to content

bih/celo-blockchain

 
 

Repository files navigation

Celo Blockchain

Official golang implementation of the Celo Blockchain, based off of the official golang implementation of the Ethereum protocol.

Building the source

Building Celo requires both a Go (version 1.9 or later) and a C compiler. You can install them using your favourite package manager. Once the dependencies are installed, run

make geth

or, to build the full suite of utilities:

make all

Executables

Celo project comes with several wrappers/executables found in the cmd directory.

Command Description
geth The main Celo Blockchain client. It is the entry point into the Celo network (alfajores or private net), capable of running as a full node (default), archive node (retaining all historical state), light node (retrieving data live), or ultralight node. It can be used by other processes as a gateway into the Celo network via JSON RPC endpoints exposed on top of HTTP, WebSocket and/or IPC transports. geth --help and the Ethereum CLI Wiki page for command line options.
abigen Source code generator to convert Celo contract definitions into easy to use, compile-time type-safe Go packages. It operates on plain Ethereum contract ABIs with expanded functionality if the contract bytecode is also available. However it also accepts Solidity source files, making development much more streamlined. Please see Ethereum's Native DApps wiki page for details.
bootnode Stripped down version of the Celo client implementation that only takes part in the network node discovery protocol, but does not run any of the higher level application protocols. It can be used as a lightweight bootstrap node to aid in finding peers in private networks.
evm Developer utility version of the EVM (Ethereum Virtual Machine) that is capable of running bytecode snippets within a configurable environment and execution mode. Its purpose is to allow isolated, fine-grained debugging of EVM opcodes (e.g. evm --code 60ff60ff --debug).
gethrpctest Developer utility tool to support the ethereum/rpc-test test suite which validates baseline conformity to the Ethereum JSON RPC specs. Please see the ethereum test suite's readme for details.
rlpdump Developer utility tool to convert binary RLP (Recursive Length Prefix) dumps (data encoding used by the Celo protocol both network as well as consensus wise) to user friendlier hierarchical representation (e.g. rlpdump --hex CE0183FFFFFFC4C304050583616263).
puppeth a CLI wizard that aids in creating a new Celo network.

Running Celo

Please see the docs page for more instructions on how to run a Celo node conencted to the Alfajores testnet.

Configuration

As an alternative to passing the numerous flags to the Celo binary, you can also pass a configuration file via:

$ geth --config /path/to/your_config.toml

To get an idea how the file should look like you can use the dumpconfig subcommand to export your existing configuration:

$ geth --your-favourite-flags dumpconfig

Note: This works only with celo v1.6.0 and above.

Contribution

Thank you for considering to help out with the source code! We welcome contributions from anyone on the internet, and are grateful for even the smallest of fixes!

If you'd like to contribute to go-ethereum, please fork, fix, commit and send a pull request for the maintainers to review and merge into the main code base. If you wish to submit more complex changes though, please check up with the core devs first on the official Celo forum to ensure those changes are in line with the general philosophy of the project and/or get some early feedback which can make both your efforts much lighter as well as our review and merge procedures quick and simple.

Please make sure your contributions adhere to our coding guidelines:

  • Code must adhere to the official Go formatting guidelines (i.e. uses gofmt).
  • Code must be documented adhering to the official Go commentary guidelines.
  • Pull requests need to be based on and opened against the master branch.
  • Commit messages should be prefixed with the package(s) they modify.
    • E.g. "eth, rpc: make trace configs optional"

License

The celo-blockchain library (i.e. all code outside of the cmd directory) is licensed under the GNU Lesser General Public License v3.0, also included in our repository in the COPYING.LESSER file.

The celo-blockchain binaries (i.e. all code inside of the cmd directory) is licensed under the GNU General Public License v3.0, also included in our repository in the COPYING file.

About

Official repository for the golang Celo Blockchain

Resources

License

LGPL-3.0, GPL-3.0 licenses found

Licenses found

LGPL-3.0
COPYING.LESSER
GPL-3.0
COPYING

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Go 88.5%
  • C 4.9%
  • JavaScript 4.0%
  • C++ 0.8%
  • Python 0.3%
  • Assembly 0.3%
  • Other 1.2%