From d2a384f20f5555000c8aa9a711bc88a1c3ce2efe Mon Sep 17 00:00:00 2001 From: bptato Date: Fri, 29 Mar 2024 17:30:15 +0100 Subject: term: flush stdout in anyKey --- src/local/term.nim | 1 + 1 file changed, 1 insertion(+) (limited to 'src/local') diff --git a/src/local/term.nim b/src/local/term.nim index 29a0a68b..e8f989cd 100644 --- a/src/local/term.nim +++ b/src/local/term.nim @@ -212,6 +212,7 @@ proc isatty*(term: Terminal): bool = proc anyKey*(term: Terminal; msg = "[Hit any key]") = if term.isatty(): term.outfile.write(term.clearEnd() & msg) + term.outfile.flushFile() discard term.istream.sreadChar() proc resetFormat(term: Terminal): string = -- cgit 1.4.1-2-gfad0