def run(): global shellface global mm ch = command_handler.Commandhandler(mm, False) while True: try: setFace() command = input(shellface + " ") ch.handle(command) except KeyboardInterrupt: sys.exit()
def run(scf): global mm scriptline = 0 ch = command_handler.Commandhandler(mm, False) while True: try: if scriptline == len(scf): sys.exit(0) command = scf[scriptline][0] scriptline += 1 ch.handle(command) except KeyboardInterrupt: print() sys.exit(0)
def run(): global shellface global mm ch = command_handler.Commandhandler(mm, False) while True: try: setFace() command = input(shellface + " ") ch.handle(command) except KeyboardInterrupt: if mm.moduleLoaded == 0: print() sys.exit(0) else: print() mm.moduleLoaded = 0 mm.moduleName = ""
def run(): global shellface global mm ch = command_handler.Commandhandler(mm, False) while True: try: setFace() command = input(shellface + " ") ch.handle(command) except KeyboardInterrupt: if mm.moduleLoaded == 0: print() sys.exit(0) else: print() mm.moduleLoaded = 0 mm.moduleName = "" print(colors.bold + colors.red + "Ctrl + C detected, going back..." + colors.end)
def __init__(self, allowPrint): self.allowPrint = allowPrint self.mm = ModuleManager self.ch = command_handler.Commandhandler(self.mm, True)