Skip to content

Commit

Permalink
Align the percentage output
Browse files Browse the repository at this point in the history
Left pad with whitespace so that the 100% line doesn't pop out of alignment.
  • Loading branch information
Robert Purcell authored and grogy committed Oct 2, 2023
1 parent 545ee3c commit 7ce7891
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/Outputs/TextOutput.php
Original file line number Diff line number Diff line change
Expand Up @@ -194,9 +194,9 @@ protected function writeMark($type)

protected function writePercent()
{
$percent = floor($this->checkedFiles / $this->totalFileCount * 100);
$percent = $this->stringWidth(floor($this->checkedFiles / $this->totalFileCount * 100), 3);
$current = $this->stringWidth($this->checkedFiles, strlen($this->totalFileCount));
$this->writeLine(" $current/$this->totalFileCount ($percent %)");
$this->writeLine(" $current/$this->totalFileCount ($percent%)");
}

/**
Expand Down

0 comments on commit 7ce7891

Please sign in to comment.