Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Progress bar goes to new line under windows #132

Open
marcovalloni opened this issue Apr 20, 2018 · 4 comments
Open

Progress bar goes to new line under windows #132

marcovalloni opened this issue Apr 20, 2018 · 4 comments

Comments

@marcovalloni
Copy link
Contributor

marcovalloni commented Apr 20, 2018

The progressbar instead of updating the current row print a new row with the updated values.

To fix this I've found that can be esily fixed by changing into Bar.php line 58 from

$size = Shell::columns();

to

$size = Shell::columns() - 1;

If it was ok as I fix I can also make a pull request for it.

Currently I've not tested it under others OS.

@schlessera schlessera added the bug label Apr 20, 2018
@schlessera
Copy link
Member

@marcovalloni That will probably break all other systems, though. You'd need to add this change conditionally for Windows only.

@marcovalloni
Copy link
Contributor Author

Yes, that wasn't a problem at all, I'll add a check for windows.

But I'll make some other checks because there's the same problem also to notify\dot and notify\spinner that uses the Streams::out_padded method.

@schlessera
Copy link
Member

@marcovalloni Did #131 actually fix this issue? Or is this still happening on Windows?

@marcovalloni
Copy link
Contributor Author

I've to make additional researches for this bug, in general under windows everything that is rewriting the line goes to a new line. I don't have much time in the last period.

With this fix I've fixed only the progressbar but also spinner and dots have the same issue.

I think that was a problem with the fact that windows move the pointer to the new line when it reach the last character of the line instead of keeping the same line.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants