File tree Expand file tree Collapse file tree 1 file changed +5
-8
lines changed Expand file tree Collapse file tree 1 file changed +5
-8
lines changed Original file line number Diff line number Diff line change @@ -466,19 +466,16 @@ private function overwrite($message)
466466 {
467467 if ($ this ->overwrite ) {
468468 if (!$ this ->firstRun ) {
469- // Move the cursor to the beginning of the line
470- $ this ->output ->write ("\x0D" );
471-
472- // Erase the line
473- $ this ->output ->write ("\x1B[2K " );
474-
475469 // Erase previous lines
476470 if ($ this ->formatLineCount > 0 ) {
477- $ this -> output -> write ( str_repeat ("\x1B[1A \x1B[2K " , $ this ->formatLineCount )) ;
471+ $ message = str_repeat ("\x1B[1A \x1B[2K " , $ this ->formatLineCount ). $ message ;
478472 }
473+
474+ // Move the cursor to the beginning of the line and erase the line
475+ $ message = "\x0D\x1B[2K $ message " ;
479476 }
480477 } elseif ($ this ->step > 0 ) {
481- $ this -> output -> writeln ( '' ) ;
478+ $ message = PHP_EOL . $ message ;
482479 }
483480
484481 $ this ->firstRun = false ;
You can’t perform that action at this time.
0 commit comments