SyntaxFix
Write A Post
Hire A Developer
Questions
In Windows console (Linux, too), you should replace '\r' with its equivalent code \033[0G:
'\r'
\033[0G
process.stdout.write('ok\033[0G');
This uses a VT220 terminal escape sequence to send the cursor to the first column.