Description:
Command-line REPL javascript console. web3.js
provides access to an Ethereum blockchain. Compiled contracts are represented as objects. Each deployed contract (with available dapp-deploy
metadata) is associated with its on-chain address.
Installation:
npm install -g @warren-bank/dapp-console
Simple Example:
lxterminal -e testrpc
mkdir ~/my_dapp
cd ~/my_dapp
dapp init
dapp deploy
dapp console
Options:
$ dapp-console --help
Command-line REPL javascript console.
'Web3.js' provides access to an Ethereum blockchain.
Compiled contracts are represented as objects.
Each deployed contract (with available 'dapp-deploy' metadata)
is associated with its on-chain address.
Usage: dapp-console [options]
Options:
-h, --host Ethereum JSON-RPC server hostname [string] [default: "localhost"]
-p, --port Ethereum JSON-RPC server port number [number] [default: 8545]
--tls, --https, --ssl Require TLS handshake (https:) to connect to Ethereum JSON-RPC server [boolean] [default: false]
-d, --contracts_directory Path to directory containing all contract artifacts: (.abi, .deployed)
note: The default path assumes that the current directory is the root of a compiled "dapp" project. [string] [default: "./out"]
-i, --input_file Path to javascript file to execute, then quit. [string]
-e, --execute Inline javascript to execute, then quit [string]
--help Show help [boolean]
Examples:
dapp-console connect to: "http://localhost:8545"
dapp-console -h "mainnet.infura.io" -p 443 --ssl connect to: "https://mainnet.infura.io:443"
dapp-console -d "/path/to/compiled/contracts" load contracts into REPL console
dapp-console -i "/path/to/script.js" execute a script file
dapp-console -e 'console.log("unlocked accounts:", "\n", web3.eth.accounts)' execute an inline script
copyright: Warren Bank <github.com/warren-bank>
license: GPLv2
Legal: