Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 2 additions & 3 deletions blink/internal/reporter/reporter.go
Original file line number Diff line number Diff line change
Expand Up @@ -31,14 +31,13 @@ func Report(w io.Writer, results []runner.FileResult, isFixer bool) int {
if !isFixer {
f.reportFileDiffs(results)
}
f.newLine(1)

if len(results) == 0 {
f.success("No errors found. Great job - your code is shiny in style!")
return 0
}

f.newLine(1)
f.newLine(2)

n := len(results)
if isFixer {
Expand All @@ -62,7 +61,7 @@ func Report(w io.Writer, results []runner.FileResult, isFixer bool) int {

// Footer prints an ECS-style run summary: files scanned, time and memory.
func Footer(w io.Writer, files int, d time.Duration, memBytes uint64) {
_, _ = fmt.Fprintf(w, "\n // %d files · %s · %d MB\n", files, d.Truncate(time.Millisecond), memBytes/(1024*1024))
_, _ = fmt.Fprintf(w, " // %d files · %s · %d MB\n", files, d.Truncate(time.Millisecond), memBytes/(1024*1024))
}

func newFormatter(w io.Writer) formatter {
Expand Down
1 change: 0 additions & 1 deletion src/Console/Command/CheckCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,6 @@ private function printRunFooter(int $filesCount, float $startTime): void
$elapsedMilliseconds = (int) round((microtime(true) - $startTime) * 1000);
$peakMemoryMegabytes = (int) round(memory_get_peak_usage(true) / 1024 / 1024);

$this->easyCodingStandardStyle->newLine();
$this->easyCodingStandardStyle->writeln(
sprintf(' // %d files · %dms · %d MB', $filesCount, $elapsedMilliseconds, $peakMemoryMegabytes)
);
Expand Down
4 changes: 1 addition & 3 deletions src/Console/Output/ConsoleOutputFormatter.php
Original file line number Diff line number Diff line change
Expand Up @@ -31,15 +31,13 @@ public function report(ErrorAndDiffResult $errorAndDiffResult, Configuration $co
$this->reportFileDiffs($errorAndDiffResult->getFileDiffs());
}

$this->easyCodingStandardStyle->newLine(1);

if ($errorAndDiffResult->getErrorCount() === 0 && $errorAndDiffResult->getFileDiffsCount() === 0) {
$this->easyCodingStandardStyle->success('No errors found. Great job - your code is shiny in style!');

return $this->exitCodeResolver->resolve($errorAndDiffResult, $configuration);
}

$this->easyCodingStandardStyle->newLine();
$this->easyCodingStandardStyle->newLine(2);

if ($configuration->isFixer()) {
$this->printAfterFixerStatus($errorAndDiffResult, $configuration);
Expand Down
Loading