def postcmd(self, stop, line): StopWatch.stop("command") if Default.timer: print("Timer: {:.4f}s ({})".format(StopWatch.get("command"), line.strip())) return stop
def postcmd(self, stop, line): StopWatch.stop("command") if Default.timer(): print("Timer: {:.4f}s ({})".format(StopWatch.get("command"), line)) return stop
def precmd(self, line): StopWatch.start("command") return line