more feedback when running a script
This commit is contained in:
parent
596f64f839
commit
eabcd5fa56
|
@ -76,7 +76,12 @@ if __name__ == '__main__':
|
|||
with open(sys.argv[1]) as f:
|
||||
lines = f.readlines()
|
||||
for line in lines:
|
||||
command(line)
|
||||
try:
|
||||
print("command#", line.strip())
|
||||
command(line)
|
||||
except (KeyboardInterrupt):
|
||||
break
|
||||
print("command#", "exit")
|
||||
else:
|
||||
import readline # for input history and line editing
|
||||
while True:
|
||||
|
|
Loading…
Reference in New Issue