diff options
author | obscuren <geffobscura@gmail.com> | 2014-05-19 19:04:31 +0800 |
---|---|---|
committer | obscuren <geffobscura@gmail.com> | 2014-05-19 19:04:31 +0800 |
commit | 16421106d47efb65331ed9f0499f12038158cbf1 (patch) | |
tree | 2a525671c3022b9465c009dfe0c8979f9389c53c /ethereum/javascript_console.go | |
parent | 3b7707c3fd2f99ee1019b8214cba1784af519f53 (diff) | |
download | dexon-16421106d47efb65331ed9f0499f12038158cbf1.tar dexon-16421106d47efb65331ed9f0499f12038158cbf1.tar.gz dexon-16421106d47efb65331ed9f0499f12038158cbf1.tar.bz2 dexon-16421106d47efb65331ed9f0499f12038158cbf1.tar.lz dexon-16421106d47efb65331ed9f0499f12038158cbf1.tar.xz dexon-16421106d47efb65331ed9f0499f12038158cbf1.tar.zst dexon-16421106d47efb65331ed9f0499f12038158cbf1.zip |
Added multi-line support
Diffstat (limited to 'ethereum/javascript_console.go')
-rw-r--r-- | ethereum/javascript_console.go | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/ethereum/javascript_console.go b/ethereum/javascript_console.go index 884b9a629..1e1ae0e48 100644 --- a/ethereum/javascript_console.go +++ b/ethereum/javascript_console.go @@ -101,14 +101,15 @@ func (self *JSRE) Run(code string) (otto.Value, error) { type JSRepl struct { re *JSRE + + prompt string } func NewJSRepl(ethereum *eth.Ethereum) *JSRepl { - return &JSRepl{re: NewJSRE(ethereum)} + return &JSRepl{re: NewJSRE(ethereum), prompt: "> "} } func (self *JSRepl) Start() { - fmt.Println("Eth JavaScript console") self.read() } |