Changeset View
Changeset View
Standalone View
Standalone View
src/lint/linter/ArcanistCoffeeLintLinter.php
Show First 20 Lines • Show All 88 Lines • ▼ Show 20 Lines | if (count($output) != 1) { | ||||
return false; | return false; | ||||
} | } | ||||
foreach ($output as $reports) { | foreach ($output as $reports) { | ||||
foreach ($reports as $report) { | foreach ($reports as $report) { | ||||
// Column number is not provided in the output. | // Column number is not provided in the output. | ||||
// See https://github.com/clutchski/coffeelint/issues/87 | // See https://github.com/clutchski/coffeelint/issues/87 | ||||
$message = id(new ArcanistLintMessage()) | $message = (new ArcanistLintMessage()) | ||||
->setPath($path) | ->setPath($path) | ||||
->setLine($report['lineNumber']) | ->setLine($report['lineNumber']) | ||||
->setCode($this->getLinterName()) | ->setCode($this->getLinterName()) | ||||
->setName(ucwords(str_replace('_', ' ', $report['name']))) | ->setName(ucwords(str_replace('_', ' ', $report['name']))) | ||||
->setDescription($report['message']) | ->setDescription($report['message']) | ||||
->setOriginalText(idx($report, 'line')); | ->setOriginalText(idx($report, 'line')); | ||||
switch ($report['level']) { | switch ($report['level']) { | ||||
Show All 30 Lines |
Content licensed under Creative Commons Attribution-ShareAlike 4.0 (CC-BY-SA) unless otherwise noted; code licensed under Apache 2.0 or other open source licenses. · CC BY-SA 4.0 · Apache 2.0