Skip to content
This repository has been archived by the owner on Nov 15, 2021. It is now read-only.

Commit

Permalink
add compile/build commands back in
Browse files Browse the repository at this point in the history
  • Loading branch information
localhuman committed Oct 3, 2017
1 parent 2c29d32 commit 9c61b0f
Show file tree
Hide file tree
Showing 3 changed files with 27 additions and 4 deletions.
11 changes: 11 additions & 0 deletions boa/tests/src/EventTest.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@

def Main():


a = 2

b = 5

c = a + b

return c
8 changes: 4 additions & 4 deletions neo/VM/ExecutionEngine.py
Original file line number Diff line number Diff line change
Expand Up @@ -798,10 +798,10 @@ def StepInto(self):
else:
op = self.CurrentContext.OpReader.ReadByte(do_ord=False)

opname = ToName(op)
print("____________________________________________________")
print("%s -> %s" % (op, opname))
print("-----------------------------------")
# opname = ToName(op)
# print("____________________________________________________")
# print("%s -> %s" % (op, opname))
# print("-----------------------------------")

try:
self.ExecuteOp(op, self.CurrentContext)
Expand Down
12 changes: 12 additions & 0 deletions prompt.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@
from neo.Wallets.KeyPair import KeyPair
from neo.Network.NodeLeader import NodeLeader
from neo.Prompt.Commands.Invoke import InvokeContract,TestInvokeContract,test_invoke,test_deploy_and_invoke
from neo.Prompt.Commands.BuildNRun import BuildAndRun,LoadAndRun
from neo.Prompt.Commands.LoadSmartContract import LoadContract,GatherContractDetails,GatherLoadedContractParams
from neo.Prompt.Utils import get_arg
from neo import Settings
Expand All @@ -39,6 +40,7 @@
from prompt_toolkit.contrib.completers import WordCompleter
from prompt_toolkit.history import InMemoryHistory

from boa.boa import Compiler

logname = 'prompt.log'
logging.basicConfig(
Expand Down Expand Up @@ -278,6 +280,12 @@ def do_import(self, arguments):
return


def do_build(self, arguments):
BuildAndRun(arguments, self.Wallet)

def do_load_n_run(self, arguments):
LoadAndRun(arguments, self.Wallet)

def do_export(self, arguments):
item = get_arg(arguments)

Expand Down Expand Up @@ -774,6 +782,10 @@ def run(self):
self.do_create(arguments)
elif command == 'open':
self.do_open(arguments)
elif command == 'build':
self.do_build(arguments)
elif command == 'load_run':
self.do_load_n_run(arguments)
elif command == 'import':
self.do_import(arguments)
elif command == 'export':
Expand Down

0 comments on commit 9c61b0f

Please sign in to comment.