From: David Cramer Date: Mon, 3 Dec 2012 23:25:16 +0000 (-0800) Subject: canRun should return false on scala linter instead of raising an exception X-Git-Tag: conduit-6~5 X-Git-Url: http://git.khamidou.com/?a=commitdiff_plain;h=0d1d04e434b06ce992b539e60df0aa6c35d738e7;p=arcanist.git canRun should return false on scala linter instead of raising an exception Summary: This was causing the following error in environments that didnt have scala configured: Some linters failed: - ArcanistScalaSBTLinter: ArcanistUsageException: This directory does not appear to be maintained by SBT, as we can't seem to find a working build file (project/Build.scala or build.sbt). Test Plan: . Reviewers: epriestley Reviewed By: epriestley CC: aran, Korvin Differential Revision: https://secure.phabricator.com/D4070 --- diff --git a/src/lint/linter/ArcanistScalaSBTLinter.php b/src/lint/linter/ArcanistScalaSBTLinter.php index cccc8b22..8081d645 100644 --- a/src/lint/linter/ArcanistScalaSBTLinter.php +++ b/src/lint/linter/ArcanistScalaSBTLinter.php @@ -30,10 +30,7 @@ final class ArcanistScalaSBTLinter extends ArcanistLinter { // Hell. We let the build system handle this for us. if (!Filesystem::pathExists('project/Build.scala') && !Filesystem::pathExists('build.sbt')) { - throw new ArcanistUsageException( - "This directory does not appear to be maintained by SBT, as we can't ". - "seem to find a working build file (project/Build.scala or ". - "build.sbt)."); + return false; } return true; }