Skip to content

Instantly share code, notes, and snippets.

@bitgord
Last active December 8, 2016 19:48
Show Gist options
  • Save bitgord/67df0b8ba0589e20c3f58c6b1e3c7f91 to your computer and use it in GitHub Desktop.
Save bitgord/67df0b8ba0589e20c3f58c6b1e3c7f91 to your computer and use it in GitHub Desktop.
Quick setup with Geth and Sol Console
// Run Command from Terminal
geth --rpc --rpcapi="db,eth,net,web3,personal" --rpcport "8545" --rpcaddr "127.0.0.1" --rpccorsdomain "localhost" console
// Check Sol is Configured
eth.getCompilers()
// In a New Terminal Window Run TestRPC
cd ~PATH-TO-FILE
testrpc
// Check Version of API
web3.version.api
// Make var
var version = web3.version.api;
// Check Version of Node
web3.version.node
// Check Version Network
web3.version.network
// Check Version of Ethereum
web3.version.ethereum
// Set New Provider
web3.setProvider(new web3.providers.HttpProvider('http://localhost:8545'));
// Check New Provider
web3.currentProvider
web3.isConnected()
// Create a hash
var hash = web3.sha3("Some string to be hashed");
var hashOfHash = web3.sha3(hash, {encoding: 'hex'});
If this all works it is working.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment