From 4b2d8e3f69c2bdd672a490b306315f57e7729a09 Mon Sep 17 00:00:00 2001 From: Joshua Spence Date: Tue, 7 Apr 2015 07:26:09 +1000 Subject: [PATCH] Don't pass data to `jshint` via STDIN Summary: Fixes T7464. JSHint is unable to exclude files from linting (via the `jshintignore` file) if the data is piped through `STDIN`. An alternative would be to pass `$options[] = '--filename='.$this->getActivePath()`, but `$this->getActivePath()` is not set when the command arguments are constructed. Test Plan: Created a file and linted it with `ArcanistJSHintLinter`. Was able to exclude the file from linting with a `jshintignore` file. Reviewers: epriestley, #blessed_reviewers Reviewed By: epriestley, #blessed_reviewers Subscribers: Korvin, epriestley Maniphest Tasks: T7464 Differential Revision: https://secure.phabricator.com/D12298 --- src/lint/linter/ArcanistJSHintLinter.php | 8 -------- 1 file changed, 8 deletions(-) diff --git a/src/lint/linter/ArcanistJSHintLinter.php b/src/lint/linter/ArcanistJSHintLinter.php index 47483d4c..7a730db1 100644 --- a/src/lint/linter/ArcanistJSHintLinter.php +++ b/src/lint/linter/ArcanistJSHintLinter.php @@ -73,14 +73,6 @@ final class ArcanistJSHintLinter extends ArcanistExternalLinter { return pht('Install JSHint using `npm install -g jshint`.'); } - public function supportsReadDataFromStdin() { - return true; - } - - public function getReadDataFromStdinFilename() { - return '-'; - } - protected function getMandatoryFlags() { $options = array(); -- 2.43.0