Changeset View
Changeset View
Standalone View
Standalone View
src/lint/linter/ArcanistJSHintLinter.php
| Show All 11 Lines | public function getInfoName() { | ||||
| return 'JSHint'; | return 'JSHint'; | ||||
| } | } | ||||
| public function getInfoURI() { | public function getInfoURI() { | ||||
| return 'http://www.jshint.com'; | return 'http://www.jshint.com'; | ||||
| } | } | ||||
| public function getInfoDescription() { | public function getInfoDescription() { | ||||
| return pht('Use `jshint` to detect issues with JavaScript source files.'); | return pht( | ||||
| 'Use `%s` to detect issues with JavaScript source files.', | |||||
| 'jshint'); | |||||
| } | } | ||||
| public function getLinterName() { | public function getLinterName() { | ||||
| return 'JSHint'; | return 'JSHint'; | ||||
| } | } | ||||
| public function getLinterConfigurationName() { | public function getLinterConfigurationName() { | ||||
| return 'jshint'; | return 'jshint'; | ||||
| Show All 36 Lines | public function getVersion() { | ||||
| if (preg_match($regex, $stderr, $matches)) { | if (preg_match($regex, $stderr, $matches)) { | ||||
| return $matches['version']; | return $matches['version']; | ||||
| } else { | } else { | ||||
| return false; | return false; | ||||
| } | } | ||||
| } | } | ||||
| public function getInstallInstructions() { | public function getInstallInstructions() { | ||||
| return pht('Install JSHint using `npm install -g jshint`.'); | return pht('Install JSHint using `%s`.', 'npm install -g jshint'); | ||||
| } | } | ||||
| protected function getMandatoryFlags() { | protected function getMandatoryFlags() { | ||||
| $options = array(); | $options = array(); | ||||
| $options[] = '--reporter='.dirname(realpath(__FILE__)).'/reporter.js'; | $options[] = '--reporter='.dirname(realpath(__FILE__)).'/reporter.js'; | ||||
| if ($this->jshintrc) { | if ($this->jshintrc) { | ||||
| ▲ Show 20 Lines • Show All 95 Lines • Show Last 20 Lines | |||||