diff options
author | Bas van Kervel <bas@ethdev.com> | 2015-06-14 01:02:46 +0800 |
---|---|---|
committer | Bas van Kervel <bas@ethdev.com> | 2015-06-14 01:02:46 +0800 |
commit | 2a0528303fb18dcc6799405d62a3a6f19da20b4a (patch) | |
tree | a1cf45920c9b5e8fb118791d8c3c28ce23fbe6ad /cmd/console/main.go | |
parent | 6f5c6150b7060b6b2ee68ac95b30f46c5c2c7f90 (diff) | |
download | go-tangerine-2a0528303fb18dcc6799405d62a3a6f19da20b4a.tar go-tangerine-2a0528303fb18dcc6799405d62a3a6f19da20b4a.tar.gz go-tangerine-2a0528303fb18dcc6799405d62a3a6f19da20b4a.tar.bz2 go-tangerine-2a0528303fb18dcc6799405d62a3a6f19da20b4a.tar.lz go-tangerine-2a0528303fb18dcc6799405d62a3a6f19da20b4a.tar.xz go-tangerine-2a0528303fb18dcc6799405d62a3a6f19da20b4a.tar.zst go-tangerine-2a0528303fb18dcc6799405d62a3a6f19da20b4a.zip |
added batch mode to console
Diffstat (limited to 'cmd/console/main.go')
-rw-r--r-- | cmd/console/main.go | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/cmd/console/main.go b/cmd/console/main.go index e8dd412ba..00a9ca9c4 100644 --- a/cmd/console/main.go +++ b/cmd/console/main.go @@ -40,7 +40,7 @@ const ( var ( gitCommit string // set via linker flag nodeNameVersion string - app = utils.NewApp(Version, "the ether console") + app = utils.NewApp(Version, "the geth console") ) func init() { @@ -93,8 +93,11 @@ func main() { func run(ctx *cli.Context) { jspath := ctx.GlobalString(utils.JSpathFlag.Name) ipcpath := utils.IpcSocketPath(ctx) - repl := newJSRE(jspath, ipcpath) - repl.welcome(ipcpath) - repl.interactive() + + if ctx.Args().Present() { + repl.batch(ctx.Args()) + } else { + repl.interactive(ipcpath) + } } |