cmd/ethereum: allow multiple js files
This commit is contained in:
parent
487f68ec48
commit
d1e04f7388
@ -159,13 +159,13 @@ func runjs(ctx *cli.Context) {
|
||||
startEth(ctx, eth)
|
||||
if len(ctx.Args()) == 0 {
|
||||
runREPL(eth)
|
||||
} else {
|
||||
for _, file := range ctx.Args() {
|
||||
execJsFile(eth, file)
|
||||
}
|
||||
}
|
||||
eth.Stop()
|
||||
eth.WaitForShutdown()
|
||||
} else if len(ctx.Args()) == 1 {
|
||||
execJsFile(eth, ctx.Args()[0])
|
||||
} else {
|
||||
utils.Fatalf("This command can handle at most one argument.")
|
||||
}
|
||||
}
|
||||
|
||||
func startEth(ctx *cli.Context, eth *eth.Ethereum) {
|
||||
|
Loading…
Reference in New Issue
Block a user