]> khamidou — GitHub mirrors - arcanist.git/commitdiff
Don't build unused linters for the `ArcanistConfigurationDrivenLintEngine`
authorAviv Eyal <avivey@gmail.com>
Wed, 9 Jul 2014 22:33:58 +0000 (15:33 -0700)
committerepriestley <git@epriestley.com>
Wed, 9 Jul 2014 22:33:58 +0000 (15:33 -0700)
Summary: Fixes T5124.

Test Plan: `arc lint` on a Phabricator diff that doesn't have JS files doesn't complain on missing JSHint.

Reviewers: #blessed_reviewers, joshuaspence, epriestley

Reviewed By: joshuaspence

Subscribers: epriestley, Korvin

Maniphest Tasks: T5124

Differential Revision: https://secure.phabricator.com/D9843

src/lint/engine/ArcanistConfigurationDrivenLintEngine.php

index e812f4dec788daea1e620cc5f0e03e3a99f566ed..88eeb9d8aa580d347e7cf481910a6c8833c325b5 100644 (file)
@@ -121,10 +121,10 @@ final class ArcanistConfigurationDrivenLintEngine extends ArcanistLintEngine {
         count($paths),
         $name);
 
-      $linter->setPaths($paths);
-
-
-      $built_linters[] = $linter;
+      if ($paths) {
+        $linter->setPaths($paths);
+        $built_linters[] = $linter;
+      }
     }
 
     return $built_linters;