php-parallel-lint / PHP-Parallel-Lint

This tool check syntax of PHP files faster than serial check with fancier output.
Other
281 stars 21 forks source link

Align the percentage output #140

Closed robertology closed 11 months ago

robertology commented 1 year ago

Left pad with whitespace so that the 100% line doesn't pop out of alignment.

Before:

............................................................  60/337 (17 %)
............................................................ 120/337 (35 %)
............................................................ 180/337 (53 %)
............................................................ 240/337 (71 %)
............................................................ 300/337 (89 %)
.....................................                        337/337 (100 %)

After:

............................................................  60/337 ( 17%)
............................................................ 120/337 ( 35%)
............................................................ 180/337 ( 53%)
............................................................ 240/337 ( 71%)
............................................................ 300/337 ( 89%)
.....................................                        337/337 (100%)
grogy commented 11 months ago

@jrfnl I suggest merge it with one change - add space between percent value and percent mark. What do you mean?

jrfnl commented 11 months ago

@jrfnl I suggest merge it with one change - add space between percent value and percent mark. What do you mean?

Sounds good to me.

robertology commented 11 months ago

Sorry, I never got back to you on the comment from months ago.

For the space before the %, I would say that is extremely unusual. Just like I wouldn't expect to see $ 15.34; there usually isn't whitespace separating those symbols. The changes here have the output matching the style of the phpunit output. But if you'd like to have the additional space in there, I can put it back.

And by the way, if I recall correctly, I put the explicit 3 in there because I saw it done elsewhere in the code and that was an attempt to match the existing codebase.

grogy commented 11 months ago

Thank you, your opinion sounds good. I merge it