mirror of
https://we.phorge.it/source/arcanist.git
synced 2024-11-26 00:32:41 +01:00
Don't use xhpast binary to compute xhpastlinter cache version if the binary doesn't exist
Summary: The binary may not be built, in which case this raises a warning. Test Plan: Will make @zeeg test. Reviewers: zeeg, vrana Reviewed By: vrana CC: aran Differential Revision: https://secure.phabricator.com/D4569
This commit is contained in:
parent
880964af83
commit
7f93b7de02
1 changed files with 6 additions and 1 deletions
|
@ -156,7 +156,12 @@ final class ArcanistXHPASTLinter extends ArcanistLinter {
|
|||
}
|
||||
|
||||
public function getCacheVersion() {
|
||||
return '2-'.md5_file(xhpast_get_binary_path());
|
||||
$version = '2';
|
||||
$path = xhpast_get_binary_path();
|
||||
if (Filesystem::pathExists($path)) {
|
||||
$version .= '-'.md5_file($path);
|
||||
}
|
||||
return $version;
|
||||
}
|
||||
|
||||
public function lintPath($path) {
|
||||
|
|
Loading…
Reference in a new issue