From 0a7dbd2d095d381b2aa89375afa5aa27144ca26f Mon Sep 17 00:00:00 2001 From: Alan Verbner Date: Sat, 22 Sep 2018 16:54:57 -0300 Subject: [PATCH] Resolves #7 Resolves #8 --- commands.js | 12 + contracts.js => components/contracts.js | 0 .../contracts}/erc20-abi.json | 0 .../contracts}/erc721-abi.json | 0 {helpers => components}/network.js | 0 components/repl.js | 21 + .../ui-helpers}/printHeader.js | 0 .../ui-helpers}/printStatus.js | 2 +- web3Admin.js => components/web3-admin.js | 0 components/web3.js | 25 + index-eval.js | 32 + index.js | 28 +- package.json | 1 + repl.js | 14 - web3-repl.json | 738 ------------------ 15 files changed, 99 insertions(+), 774 deletions(-) create mode 100644 commands.js rename contracts.js => components/contracts.js (100%) rename {contracts => components/contracts}/erc20-abi.json (100%) rename {contracts => components/contracts}/erc721-abi.json (100%) rename {helpers => components}/network.js (100%) create mode 100644 components/repl.js rename {helpers => components/ui-helpers}/printHeader.js (100%) rename {helpers => components/ui-helpers}/printStatus.js (94%) rename web3Admin.js => components/web3-admin.js (100%) create mode 100644 components/web3.js create mode 100644 index-eval.js delete mode 100644 web3-repl.json diff --git a/commands.js b/commands.js new file mode 100644 index 0000000..179ac1e --- /dev/null +++ b/commands.js @@ -0,0 +1,12 @@ +"use strict"; + +const program = require("commander"); +const {version} = require("../package.json"); + +program + .version(version) +// .option("-s, --skip-status", "Does not show status after bootstrap") +// .option("-hf, --history-file [path]", "File path of commands history file (defaults to $HOME/.web3_repl_history)") + .command("repl", "Starts REPL mode", {isDefault: true}).alias("r") + .command("eval [expression]", "Executes a single command and quits").alias('e') + .parse(process.argv); diff --git a/contracts.js b/components/contracts.js similarity index 100% rename from contracts.js rename to components/contracts.js diff --git a/contracts/erc20-abi.json b/components/contracts/erc20-abi.json similarity index 100% rename from contracts/erc20-abi.json rename to components/contracts/erc20-abi.json diff --git a/contracts/erc721-abi.json b/components/contracts/erc721-abi.json similarity index 100% rename from contracts/erc721-abi.json rename to components/contracts/erc721-abi.json diff --git a/helpers/network.js b/components/network.js similarity index 100% rename from helpers/network.js rename to components/network.js diff --git a/components/repl.js b/components/repl.js new file mode 100644 index 0000000..c7b6a0f --- /dev/null +++ b/components/repl.js @@ -0,0 +1,21 @@ +const repl = require("repl.js"); +const instarun = require('repl.js/src/evaler/instarun'); +const Console = require('repl.js/src/utilrepl/console'); + +module.exports = (extensions, historyFile) => { + const replServer = repl.start({prompt: "> ", ignoreUndefined: true}); + + Object + .entries(extensions) + .forEach(([key, extension]) => { + replServer.context[key] = extension; + }); + + if (historyFile) + require("repl.history")(replServer, historyFile); + + return { + replServer, + instarun: (opts) => instarun(replServer, Console.Console({}), opts) + }; +} \ No newline at end of file diff --git a/helpers/printHeader.js b/components/ui-helpers/printHeader.js similarity index 100% rename from helpers/printHeader.js rename to components/ui-helpers/printHeader.js diff --git a/helpers/printStatus.js b/components/ui-helpers/printStatus.js similarity index 94% rename from helpers/printStatus.js rename to components/ui-helpers/printStatus.js index 9a0ffad..bcdf1be 100644 --- a/helpers/printStatus.js +++ b/components/ui-helpers/printStatus.js @@ -1,7 +1,7 @@ 'use strict'; const chalk = require("chalk"); -const { isETCFork } = require("./network"); +const { isETCFork } = require("../network"); const printStatus = web3 => () => { try { diff --git a/web3Admin.js b/components/web3-admin.js similarity index 100% rename from web3Admin.js rename to components/web3-admin.js diff --git a/components/web3.js b/components/web3.js new file mode 100644 index 0000000..2af8afd --- /dev/null +++ b/components/web3.js @@ -0,0 +1,25 @@ +"use strict"; + +const Web3 = require("web3"); +const utils = require("ethereumjs-util"); +const contracts = require("./contracts"); +const printStatus = require("./ui-helpers/printStatus"); +const web3Admin = require("./web3-admin"); + +const defaultProvider = "http://localhost:8545"; + +module.exports = (provider) => { + const web3 = new Web3(new Web3.providers.HttpProvider(provider || defaultProvider)); + + web3Admin.extend(web3); + + const {contract, predefinedContracts} = contracts(web3); + + return { + web3, + utils, + contract, + predefinedContracts, + status: printStatus(web3) + }; +} \ No newline at end of file diff --git a/index-eval.js b/index-eval.js new file mode 100644 index 0000000..bbc3480 --- /dev/null +++ b/index-eval.js @@ -0,0 +1,32 @@ +"use strict"; + +const program = require("commander"); +const fs = require("fs"); +const web3 = require("./components/web3"); +const repl = require("./components/repl"); +const printHeader = require("./components/ui-helpers/printHeader"); + +function runEval(expression, options) {} + +program + .option("-T, --pipe", "Does not print any status information and quit") + .option("-p, --provider [url]", "Web3JS RPC provider") + .parse(process.argv); + +if (!program.args || program.args.length !== 1) { + console.error('Expression required!'); + process.exit(1); +} + +if (!program.pipe) + printHeader(web3); + +const toEval = program.args[0]; + +const opts = fs.existsSync(toEval) + ? { file: toEval, print: true, quit: program.pipe } + : { eval: toEval, print: true, quit: program.pipe }; + +const components = web3(program.provider); +const {replServer, instarun} = repl(components); +instarun(opts); \ No newline at end of file diff --git a/index.js b/index.js index 73d26a0..58676d5 100644 --- a/index.js +++ b/index.js @@ -1,33 +1,17 @@ #!/usr/bin/env node -const Web3 = require("web3"); -const utils = require("ethereumjs-util"); const program = require("commander"); const chalk = require("chalk"); const os = require("os"); const path = require("path"); -const repl = require("./repl"); -const contracts = require("./contracts"); +require("./commands"); +return; -const printStatus = require("./helpers/printStatus"); -const printHeader = require("./helpers/printHeader"); -const web3Admin = require("./web3Admin"); +//printHeader(); +//const repl = require("./components/repl"); -const package = require("./package.json"); -const defaultProvider = "http://localhost:8545"; - -program - .version(package.version) - .option("-p, --provider [url]", "Web3JS RPC provider") - .option("-s, --skip-status", "Does not show status after bootstrap") - .option("-hf, --history-file [path]", "File path of commands history file (defaults to $HOME/.web3_repl_history)") - .parse(process.argv); - -printHeader(); - -const web3 = new Web3(new Web3.providers.HttpProvider(program.provider || defaultProvider)); if (!program.skipStatus) printStatus(web3)(); @@ -39,10 +23,12 @@ web3Admin.extend(web3); const {contract, predefinedContracts} = contracts(web3); -repl({ +const {instarun} = repl({ web3, utils, contract, predefinedContracts, status: printStatus(web3) }, historyFile); + +instarun({eval: "web3.eth.blockNumber", print: true, quit: true}); \ No newline at end of file diff --git a/package.json b/package.json index 07f3a62..b9407b0 100644 --- a/package.json +++ b/package.json @@ -19,6 +19,7 @@ "dependencies": { "chalk": "1.1.3", "commander": "2.9.0", + "console-ultimate": "2.9.0", "ethereumjs-util": "5.1.2", "repl.history": "0.1.4", "repl.js": "2.3.7", diff --git a/repl.js b/repl.js index ec2f310..e69de29 100644 --- a/repl.js +++ b/repl.js @@ -1,14 +0,0 @@ -const repl = require("repl.js"); - -module.exports = (extensions, historyFile) => { - const replServer = repl.start({prompt: "> ", ignoreUndefined: true}); - - Object - .entries(extensions) - .forEach(([key, extension]) => { - replServer.context[key] = extension; - }); - require("repl.history")(replServer, historyFile); - - return replServer; -} \ No newline at end of file diff --git a/web3-repl.json b/web3-repl.json deleted file mode 100644 index cdc0dfa..0000000 --- a/web3-repl.json +++ /dev/null @@ -1,738 +0,0 @@ -{ - "height": 19, - "duration": 57.560636, - "env": { - "SHELL": "/bin/bash", - "TERM": "xterm" - }, - "width": 151, - "command": null, - "stdout": [ - [ - 0.025455, - "\u001b[30m\u001b(B\u001b[m\u001b]0;[/h/P/web3-cli]\u0007" - ], - [ - 3.9e-05, - "\u001b[2m⏎\u001b(B\u001b[m \r⏎ \r\u001b[2K" - ], - [ - 0.000694, - "\u001b[1m\u001b[36muser\u001b[30m\u001b(B\u001b[m\u001b[33m@\u001b[1m\u001b[34mmachine\u001b[30m\u001b(B\u001b[m:\u001b[1m\u001b[32m\u001b[30m\u001b(B\u001b[m\r\n\u001b[35m$ \u001b[30m\u001b(B\u001b[m\u001b[K\u001b[132C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[C\u001b[C" - ], - [ - 0.020968, - "\u001b[30m\u001b(B\u001b[m\u001b]0;[/h/P/web3-cli]\u0007" - ], - [ - 0.000219, - "\r" - ], - [ - 0.000722, - "\u001b[A\u001b[1m\u001b[36muser\u001b[30m\u001b(B\u001b[m\u001b[33m@\u001b[1m\u001b[34mmachine\u001b[30m\u001b(B\u001b[m:\u001b[1m\u001b[32m\u001b[30m\u001b(B\u001b[m\r\n\u001b[35m$ \u001b[30m\u001b(B\u001b[m\u001b[K\u001b[132C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[C\u001b[C" - ], - [ - 1.629738, - "w\u001b[131C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[3C" - ], - [ - 0.000793, - "\u001b[131C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[3C" - ], - [ - 0.000842, - "\b\u001b[38;5;26mw\u001b[131C\u001b[30m\u001b(B\u001b[m\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[3C" - ], - [ - 0.000966, - "\u001b[38;5;240meb3-repl --help\u001b[116C\u001b[30m\u001b(B\u001b[m\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[3C" - ], - [ - 0.17507, - "\u001b[38;5;26me\u001b[38;5;240mb3-repl --help\u001b[116C\u001b[30m\u001b(B\u001b[m\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[4C" - ], - [ - 0.000736, - "\u001b[130C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[4C" - ], - [ - 0.000949, - "\b\b\u001b[31m\u001b[1mwe\u001b(B\u001b[m\u001b[38;5;240mb3-repl --help\u001b[116C\u001b[30m\u001b(B\u001b[m\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[4C" - ], - [ - 0.111185, - "\u001b[31m\u001b[1mb\u001b(B\u001b[m\u001b[38;5;240m3-repl --help\u001b[116C\u001b[30m\u001b(B\u001b[m\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[5C" - ], - [ - 0.000874, - "\u001b[129C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[5C" - ], - [ - 1.175343, - "\u001b[31m\u001b[1m3-repl --help\u001b[116C\u001b(B\u001b[m\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[18C" - ], - [ - 0.000966, - "\u001b[16D\u001b[38;5;26mweb3-repl\u001b[30m\u001b(B\u001b[m \u001b[38;5;39m--help\u001b[116C\u001b[30m\u001b(B\u001b[m\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[18C" - ], - [ - 0.551793, - "\u001b[116C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[18C\r\n\u001b[30m\u001b(B\u001b[m" - ], - [ - 0.000571, - "\u001b[30m\u001b(B\u001b[m\u001b]0;[/h/P/web3-cli]\u0007\r" - ], - [ - 0.2437, - "\r\n Usage: web3-repl [options]\r\n\r\n Options:\r\n\r\n -h, --help output usage information\r\n -V, --version output the version number\r\n -p, --provider [url] Web3JS RPC provider\r\n -s, --skip-status Does not show status after bootstrap\r\n\r\n" - ], - [ - 0.020131, - "\u001b[30m\u001b(B\u001b[m\u001b]0;[/h/P/web3-cli]\u0007\u001b[2m⏎\u001b(B\u001b[m \r⏎ \r\u001b[2K" - ], - [ - 0.000402, - "\u001b[1m\u001b[36muser\u001b[30m\u001b(B\u001b[m\u001b[33m@\u001b[1m\u001b[34mmachine\u001b[30m\u001b(B\u001b[m:\u001b[1m\u001b[32m\u001b[30m\u001b(B\u001b[m\r\n\u001b[35m$ \u001b[30m\u001b(B\u001b[m\u001b[K\u001b[132C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[C\u001b[C" - ], - [ - 0.012541, - "\u001b[30m\u001b(B\u001b[m\u001b]0;[/h/P/web3-cli]\u0007" - ], - [ - 0.000145, - "\r" - ], - [ - 0.000412, - "\u001b[A\u001b[1m\u001b[36muser\u001b[30m\u001b(B\u001b[m\u001b[33m@\u001b[1m\u001b[34mmachine\u001b[30m\u001b(B\u001b[m:\u001b[1m\u001b[32m\u001b[30m\u001b(B\u001b[m\r\n\u001b[35m$ \u001b[30m\u001b(B\u001b[m\u001b[K\u001b[132C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[C\u001b[C" - ], - [ - 1.057488, - "w\u001b[131C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[3C" - ], - [ - 0.000822, - "\u001b[131C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[3C" - ], - [ - 0.000971, - "\u001b[38;5;240meb3-repl --help\u001b[116C\u001b[30m\u001b(B\u001b[m\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[3C" - ], - [ - 0.000955, - "\b\u001b[38;5;26mw\u001b[38;5;240meb3-repl --help\u001b[116C\u001b[30m\u001b(B\u001b[m\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[3C" - ], - [ - 0.236024, - "\u001b[38;5;26me\u001b[38;5;240mb3-repl --help\u001b[116C\u001b[30m\u001b(B\u001b[m\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[4C" - ], - [ - 0.000831, - "\u001b[130C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[4C" - ], - [ - 0.000965, - "\b\b\u001b[31m\u001b[1mwe\u001b(B\u001b[m\u001b[38;5;240mb3-repl --help\u001b[116C\u001b[30m\u001b(B\u001b[m\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[4C" - ], - [ - 0.130402, - "\u001b[31m\u001b[1mb\u001b(B\u001b[m\u001b[38;5;240m3-repl --help\u001b[116C\u001b[30m\u001b(B\u001b[m\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[5C" - ], - [ - 0.000804, - "\u001b[129C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[5C" - ], - [ - 0.171594, - "\u001b[31m\u001b[1m3\u001b(B\u001b[m\u001b[38;5;240m-repl --help\u001b[116C\u001b[30m\u001b(B\u001b[m\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[6C" - ], - [ - 0.000762, - "\u001b[128C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[6C" - ], - [ - 0.492435, - "\u001b[31m\u001b[1m-\u001b(B\u001b[m\u001b[38;5;240mrepl --help\u001b[116C\u001b[30m\u001b(B\u001b[m\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[7C" - ], - [ - 0.000655, - "\u001b[127C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[7C" - ], - [ - 0.171617, - "\u001b[31m\u001b[1mr\u001b(B\u001b[m\u001b[38;5;240mepl --help\u001b[116C\u001b[30m\u001b(B\u001b[m\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[8C" - ], - [ - 0.000686, - "\u001b[126C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[8C" - ], - [ - 0.058711, - "\u001b[31m\u001b[1me\u001b(B\u001b[m\u001b[38;5;240mpl --help\u001b[116C\u001b[30m\u001b(B\u001b[m\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[9C" - ], - [ - 0.000677, - "\u001b[125C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[9C" - ], - [ - 0.252773, - "\u001b[31m\u001b[1mp\u001b(B\u001b[m\u001b[38;5;240ml --help\u001b[116C\u001b[30m\u001b(B\u001b[m\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[10C" - ], - [ - 0.000807, - "\u001b[124C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[10C" - ], - [ - 0.240689, - "\u001b[31m\u001b[1ml\u001b(B\u001b[m\u001b[38;5;240m --help\u001b[116C\u001b[30m\u001b(B\u001b[m\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[11C" - ], - [ - 0.000803, - "\u001b[123C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[11C" - ], - [ - 0.00094, - "\u001b[9D\u001b[38;5;26mweb3-repl\u001b[38;5;240m --help\u001b[116C\u001b[30m\u001b(B\u001b[m\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[11C" - ], - [ - 0.236687, - "\u001b[38;5;26mo\u001b[30m\u001b(B\u001b[m\u001b[K\u001b[122C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[12C" - ], - [ - 0.000493, - "\u001b[122C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[12C" - ], - [ - 0.000928, - "\u001b[121C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[13C" - ], - [ - 0.000849, - "\b \u001b[121C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[13C" - ], - [ - 0.412539, - "\b\u001b[K\u001b[122C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[12C" - ], - [ - 0.138307, - "\b\u001b[K\u001b[123C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[11C" - ], - [ - 0.000985, - "\u001b[9D\u001b[38;5;26mweb3-repl\u001b[123C\u001b[30m\u001b(B\u001b[m\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[11C" - ], - [ - 0.845024, - "\u001b[38;5;26mp\u001b[122C\u001b[30m\u001b(B\u001b[m\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[12C" - ], - [ - 0.000741, - "\u001b[122C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[12C" - ], - [ - 0.154929, - "\u001b[31m\u001b[1m \u001b[121C\u001b(B\u001b[m\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[13C" - ], - [ - 0.000453, - "\u001b[121C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[13C" - ], - [ - 0.000484, - "\b \u001b[121C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[13C" - ], - [ - 0.518516, - "\b\u001b[K\u001b[122C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[12C" - ], - [ - 0.140971, - "\b\u001b[K\u001b[123C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[11C" - ], - [ - 0.000803, - "\u001b[9D\u001b[38;5;26mweb3-repl\u001b[123C\u001b[30m\u001b(B\u001b[m\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[11C" - ], - [ - 0.168475, - "\b\u001b[K\u001b[124C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[10C" - ], - [ - 0.000451, - "\b\b\b\b\b\b\b\b\u001b[31m\u001b[1mweb3-rep\u001b[124C\u001b(B\u001b[m\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[10C" - ], - [ - 0.225114, - "\b\u001b[K\u001b[125C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[9C" - ], - [ - 0.31752, - "\u001b[31m\u001b[1mp\u001b[124C\u001b(B\u001b[m\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[10C" - ], - [ - 0.000709, - "\u001b[124C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[10C" - ], - [ - 0.000776, - "\u001b[38;5;240ml --help\u001b[116C\u001b[30m\u001b(B\u001b[m\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[10C" - ], - [ - 0.20527, - "\u001b[31m\u001b[1ml\u001b(B\u001b[m\u001b[38;5;240m --help\u001b[116C\u001b[30m\u001b(B\u001b[m\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[11C" - ], - [ - 0.000692, - "\u001b[123C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[11C" - ], - [ - 0.000904, - "\u001b[9D\u001b[38;5;26mweb3-repl\u001b[38;5;240m --help\u001b[116C\u001b[30m\u001b(B\u001b[m\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[11C" - ], - [ - 0.1936, - "\u001b[38;5;26m \u001b[38;5;240m--help\u001b[116C\u001b[30m\u001b(B\u001b[m\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[12C" - ], - [ - 0.000771, - "\b \u001b[38;5;240m--help\u001b[116C\u001b[30m\u001b(B\u001b[m\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[12C" - ], - [ - 1.66473, - "-\u001b[38;5;240m-help\u001b[116C\u001b[30m\u001b(B\u001b[m\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[13C" - ], - [ - 0.000762, - "\u001b[121C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[13C" - ], - [ - 0.000943, - "\b\u001b[38;5;39m-\u001b[38;5;240m-help\u001b[116C\u001b[30m\u001b(B\u001b[m\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[13C" - ], - [ - 0.309429, - "\u001b[38;5;39mp\u001b[30m\u001b(B\u001b[m\u001b[K\u001b[120C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[14C" - ], - [ - 0.000672, - "\u001b[120C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[14C" - ], - [ - 0.130824, - "\u001b[38;5;39m \u001b[119C\u001b[30m\u001b(B\u001b[m\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[15C" - ], - [ - 0.000425, - "\u001b[119C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[15C" - ], - [ - 0.00047, - "\b \u001b[119C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[15C" - ], - [ - 0.637921, - "h\u001b[118C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[16C" - ], - [ - 0.000674, - "\u001b[118C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[16C" - ], - [ - 0.00072, - "\b\u001b[38;5;39mh\u001b[118C\u001b[30m\u001b(B\u001b[m\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[16C" - ], - [ - 0.096094, - "\u001b[38;5;39mt\u001b[117C\u001b[30m\u001b(B\u001b[m\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[17C" - ], - [ - 0.00045, - "\u001b[117C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[17C" - ], - [ - 0.13778, - "\u001b[38;5;39mt\u001b[116C\u001b[30m\u001b(B\u001b[m\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[18C" - ], - [ - 0.000531, - "\u001b[116C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[18C" - ], - [ - 0.084912, - "\u001b[38;5;39mp\u001b[115C\u001b[30m\u001b(B\u001b[m\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[19C" - ], - [ - 0.00032, - "\u001b[115C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[19C" - ], - [ - 0.36242, - "\u001b[38;5;39m:\u001b[114C\u001b[30m\u001b(B\u001b[m\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[20C" - ], - [ - 0.000727, - "\u001b[114C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[20C" - ], - [ - 0.079642, - "\u001b[38;5;240mindex.js \u001b[105C\u001b[30m\u001b(B\u001b[m\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[20C" - ], - [ - 0.082154, - "\u001b[38;5;39m/\u001b[30m\u001b(B\u001b[m\u001b[K\u001b[113C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[21C" - ], - [ - 0.000757, - "\u001b[113C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[21C" - ], - [ - 0.081459, - "\u001b[38;5;240mbin/\u001b[109C\u001b[30m\u001b(B\u001b[m\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[21C" - ], - [ - 0.05346, - "\u001b[38;5;39m/\u001b[30m\u001b(B\u001b[m\u001b[K\u001b[112C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[22C" - ], - [ - 0.000717, - "\u001b[112C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[22C" - ], - [ - 0.06891, - "\u001b[38;5;240mbin/\u001b[108C\u001b[30m\u001b(B\u001b[m\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[22C" - ], - [ - 0.18863, - "\u001b[38;5;39ml\u001b[30m\u001b(B\u001b[m\u001b[K\u001b[111C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[23C" - ], - [ - 0.000787, - "\u001b[111C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[23C" - ], - [ - 0.075026, - "\u001b[38;5;240mib/\u001b[108C\u001b[30m\u001b(B\u001b[m\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[23C" - ], - [ - 0.115209, - "\u001b[38;5;39mo\u001b[30m\u001b(B\u001b[m\u001b[K\u001b[110C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[24C" - ], - [ - 0.000771, - "\u001b[110C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[24C" - ], - [ - 0.069088, - "\u001b[38;5;39mc\u001b[109C\u001b[30m\u001b(B\u001b[m\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[25C" - ], - [ - 0.000637, - "\u001b[109C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[25C" - ], - [ - 0.089336, - "\u001b[38;5;39ma\u001b[108C\u001b[30m\u001b(B\u001b[m\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[26C" - ], - [ - 0.000455, - "\u001b[108C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[26C" - ], - [ - 0.104554, - "\u001b[38;5;39ml\u001b[107C\u001b[30m\u001b(B\u001b[m\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[27C" - ], - [ - 0.00055, - "\u001b[107C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[27C" - ], - [ - 0.175144, - "\u001b[38;5;39mh\u001b[106C\u001b[30m\u001b(B\u001b[m\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[28C" - ], - [ - 0.000846, - "\u001b[106C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[28C" - ], - [ - 0.107067, - "\u001b[38;5;39mo\u001b[105C\u001b[30m\u001b(B\u001b[m\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[29C" - ], - [ - 0.000619, - "\u001b[105C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[29C" - ], - [ - 0.134512, - "\u001b[38;5;39ms\u001b[104C\u001b[30m\u001b(B\u001b[m\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[30C" - ], - [ - 0.0008, - "\u001b[104C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[30C" - ], - [ - 0.106748, - "\u001b[38;5;39mt\u001b[103C\u001b[30m\u001b(B\u001b[m\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[31C" - ], - [ - 0.000332, - "\u001b[103C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[31C" - ], - [ - 0.150074, - "\u001b[38;5;39m:\u001b[102C\u001b[30m\u001b(B\u001b[m\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[32C" - ], - [ - 0.000538, - "\u001b[102C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[32C" - ], - [ - 0.078726, - "\u001b[38;5;240mindex.js \u001b[93C\u001b[30m\u001b(B\u001b[m\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[32C" - ], - [ - 0.917187, - "\u001b[38;5;39m8\u001b[30m\u001b(B\u001b[m\u001b[K\u001b[101C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[33C" - ], - [ - 0.000779, - "\u001b[101C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[33C" - ], - [ - 1.384221, - "\u001b[38;5;39m5\u001b[100C\u001b[30m\u001b(B\u001b[m\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[34C" - ], - [ - 0.000796, - "\u001b[100C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[34C" - ], - [ - 0.266628, - "\u001b[38;5;39m4\u001b[99C\u001b[30m\u001b(B\u001b[m\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[35C" - ], - [ - 0.000814, - "\u001b[99C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[35C" - ], - [ - 0.192128, - "\u001b[38;5;39m5\u001b[98C\u001b[30m\u001b(B\u001b[m\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[36C" - ], - [ - 0.00065, - "\u001b[98C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[36C" - ], - [ - 0.969614, - "\u001b[98C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[36C\r\n\u001b[30m\u001b(B\u001b[m" - ], - [ - 0.001486, - "\u001b[30m\u001b(B\u001b[m\u001b]0;[/h/P/web3-cli]\u0007\r" - ], - [ - 0.221, - "\r\n██╗ ██╗███████╗██████╗ ██████╗ ██╗███████╗ ██████╗ ███████╗██████╗ ██╗ \r\n██║ ██║██╔════╝██╔══██╗╚════██╗ ██║██╔════╝ ██╔══██╗██╔════╝██╔══██╗██║ \r\n██║ █╗ ██║█████╗ ██████╔╝ █████╔╝ ██║███████╗ ██████╔╝█████╗ ██████╔╝██║ \r\n██║███╗██║██╔══╝ ██╔══██╗ ╚═══██╗ ██ ██║╚════██║ ██╔══██╗██╔══╝ ██╔═══╝ ██║ \r\n╚███╔███╔╝███████╗██████╔╝██████╔╝██╗╚████" - ], - [ - 5.3e-05, - "█╔╝███████║ ██║ ██║███████╗██║ ███████╗\r\n ╚══╝╚══╝ ╚══════╝╚═════╝ ╚═════╝ ╚═╝ ╚════╝ ╚══════╝ ╚═╝ ╚═╝╚══════╝╚═╝ ╚══════╝\r\n\r\n" - ], - [ - 0.49905, - "\r\n \u001b[32mProvider : http://localhost:8545\u001b[39m\r\n \u001b[32mLast Block # : 3179944\u001b[39m\r\n \u001b[32mLast Block : 0x8764693ae4258fe76d0a5f8ea527d2fcbbe0cd0c705e56aa964977524de4c430\u001b[39m\r\n \u001b[32mMining? : false\u001b[39m\r\n \u001b[32mPeer Count : 6\u001b[39m\r\n \u001b[32mWeb3 api version : 0.18.2\u001b[39m\r\n \u001b[32mETC fork? : true\u001b[39m\r\n \r\n" - ], - [ - 0.008245, - "\u001b[1G" - ], - [ - 2.6e-05, - "\u001b[0J" - ], - [ - 9.3e-05, - "> \u001b[3G" - ], - [ - 0.100122, - "w" - ], - [ - 0.159614, - "e" - ], - [ - 0.13682, - "b" - ], - [ - 0.239715, - "3" - ], - [ - 0.17966, - "." - ], - [ - 0.443437, - "e" - ], - [ - 0.115031, - "t" - ], - [ - 0.078643, - "h" - ], - [ - 0.232718, - "." - ], - [ - 0.135252, - "g" - ], - [ - 0.064728, - "e" - ], - [ - 0.127283, - "t" - ], - [ - 0.353417, - "B" - ], - [ - 0.09243, - "l" - ], - [ - 0.169652, - "o" - ], - [ - 0.065755, - "c" - ], - [ - 0.106296, - "k" - ], - [ - 0.385439, - "(" - ], - [ - 0.214998, - "0" - ], - [ - 0.340291, - ")" - ], - [ - 0.304182, - "\r\r\n" - ], - [ - 0.202687, - "{ author: \u001b[32m'0x0000000000000000000000000000000000000000'\u001b[39m,\r\n difficulty: { [String: '17179869184'] s: \u001b[33m1\u001b[39m, e: \u001b[33m10\u001b[39m, c: [ \u001b[33m17179869184\u001b[39m ] },\r\n extraData: \u001b[32m'0x11bbe8db4e347b4e8c937c1c8370e4b5ed33adb3db69cbdb7a38e1e50b1b82fa'\u001b[39m,\r\n gasLimit: \u001b[33m5000\u001b[39m,\r\n gasUsed: \u001b[33m0\u001b[39m,\r\n hash: \u001b[32m'0xd4e56740f876aef8c010b86a40d5f56745a118d0906a34e69aec8c0db1cb8fa3'\u001b[39m,\r\n logsBloom: \u001b[32m'0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000'\u001b[39m,\r\n miner: \u001b[32m'0x0000000000000000000000000000000000000000'\u001b[39m,\r\n mixH" - ], - [ - 2.7e-05, - "ash: \u001b[32m'0x0000000000000000000000000000000000000000000000000000000000000000'\u001b[39m,\r\n nonce: \u001b[32m'0x0000000000000042'\u001b[39m,\r\n number: \u001b[33m0\u001b[39m,\r\n parentHash: \u001b[32m'0x0000000000000000000000000000000000000000000000000000000000000000'\u001b[39m,\r\n receiptsRoot: \u001b[32m'0x56e81f171bcc55a6ff8345e692c0f86e5b48e01b996cadc001622fb5e363b421'\u001b[39m,\r\n sealFields: \r\n [ \u001b[32m'0x0000000000000000000000000000000000000000000000000000000000000000'\u001b[39m,\r\n \u001b[32m'0x0000000000000042'\u001b[39m ],\r\n sha3Uncles: \u001b[32m'0x1dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347'\u001b[39m,\r\n size: \u001b[33m540\u001b[39m,\r\n stateRoot: \u001b[32m'0xd7f8974fb5ac78d9ac099b9ad5018bedc2ce0a72dad1827a1709da30580f0544'\u001b[39m,\r\n timestamp: \u001b[33m0\u001b[39m,\r\n totalDifficulty: { [String: '17179869184'] s: \u001b[33m1\u001b[39m, e: \u001b[33m10\u001b[39m, c: [ \u001b[33m17179869184\u001b[39m ] },\r\n transactions: [],\r\n transactionsRoot: \u001b[32m'0x56e81f171bcc55a6ff8345e692c0f86e5b48e01b996cadc001622fb5e363b421'\u001b[39m,\r\n uncles: [] }\r\n" - ], - [ - 0.000249, - "\u001b[1G\u001b[0J" - ], - [ - 2e-05, - "> \u001b[3G" - ], - [ - 2.376383, - "s" - ], - [ - 0.145093, - "t" - ], - [ - 0.066669, - "a" - ], - [ - 0.12672, - "t" - ], - [ - 0.129038, - "u" - ], - [ - 0.084035, - "s" - ], - [ - 0.567383, - "(" - ], - [ - 0.048639, - ")" - ], - [ - 0.291497, - "\r\r\n" - ], - [ - 0.483262, - "\r\n \u001b[32mProvider : http://localhost:8545\u001b[39m\r\n \u001b[32mLast Block # : 3179946\u001b[39m\r\n \u001b[32mLast Block : 0xd44ffbb68fc6514b861f379044c4487f1d46ed5823ef03c32991091edcc3c32c\u001b[39m\r\n \u001b[32mMining? : false\u001b[39m\r\n \u001b[32mPeer Count : 7\u001b[39m\r\n \u001b[32mWeb3 api version : 0.18.2\u001b[39m\r\n \u001b[32mETC fork? : true\u001b[39m\r\n \r\n" - ], - [ - 0.000285, - "\u001b[1G\u001b[0J> \u001b[3G" - ], - [ - 0.993068, - "\u001b[30m\u001b(B\u001b[m\u001b]0;[/h/P/web3-cli]\u0007" - ], - [ - 3.5e-05, - "\u001b[2m⏎\u001b(B\u001b[m \r⏎ \r\u001b[2K" - ], - [ - 0.000617, - "\u001b[1m\u001b[36muser\u001b[30m\u001b(B\u001b[m\u001b[33m@\u001b[1m\u001b[34mmachine\u001b[30m\u001b(B\u001b[m:\u001b[1m\u001b[32m\u001b[30m\u001b(B\u001b[m\r\n\u001b[35m$ \u001b[30m\u001b(B\u001b[m\u001b[K\u001b[132C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[C\u001b[C" - ], - [ - 0.016504, - "\u001b[30m\u001b(B\u001b[m\u001b]0;[/h/P/web3-cli]\u0007" - ], - [ - 0.000218, - "\r" - ], - [ - 0.000608, - "\u001b[A\u001b[1m\u001b[36muser\u001b[30m\u001b(B\u001b[m\u001b[33m@\u001b[1m\u001b[34mmachine\u001b[30m\u001b(B\u001b[m:\u001b[1m\u001b[32m\u001b[30m\u001b(B\u001b[m\r\n\u001b[35m$ \u001b[30m\u001b(B\u001b[m\u001b[K\u001b[132C\u001b]0;[/h/P/web3-cli]\u0007\r\u001b[134C\r\u001b[C\u001b[C" - ], - [ - 0.19189, - "\r\n\u001b[30m\u001b(B\u001b[m\u001b[30m\u001b(B\u001b[m" - ], - [ - 0.000719, - "user@machine:$ " - ] - ], - "version": 1, - "title": null -} \ No newline at end of file