Changeset View
Changeset View
Standalone View
Standalone View
src/lint/linter/ArcanistPuppetLintLinter.php
Show First 20 Lines • Show All 102 Lines • ▼ Show 20 Lines | protected function parseLinterOutput($path, $err, $stdout, $stderr) { | ||||
foreach ($lines as $line) { | foreach ($lines as $line) { | ||||
$matches = explode('|', $line, 5); | $matches = explode('|', $line, 5); | ||||
if (count($matches) < 5) { | if (count($matches) < 5) { | ||||
continue; | continue; | ||||
} | } | ||||
$message = id(new ArcanistLintMessage()) | $message = (new ArcanistLintMessage()) | ||||
->setPath($path) | ->setPath($path) | ||||
->setLine($matches[0]) | ->setLine($matches[0]) | ||||
->setChar($matches[1]) | ->setChar($matches[1]) | ||||
->setCode($this->getLinterName()) | ->setCode($this->getLinterName()) | ||||
->setName(ucwords(str_replace('_', ' ', $matches[3]))) | ->setName(ucwords(str_replace('_', ' ', $matches[3]))) | ||||
->setDescription(ucfirst($matches[4])); | ->setDescription(ucfirst($matches[4])); | ||||
switch ($matches[2]) { | switch ($matches[2]) { | ||||
Show All 20 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