From: vrana Date: Mon, 28 Jan 2013 23:18:12 +0000 (-0800) Subject: Ignore untracked files in lint repository cache key X-Git-Url: http://git.khamidou.com/?a=commitdiff_plain;h=fd909479d0e2e5c19a5b91049f4980c12a4e0964;p=arcanist.git Ignore untracked files in lint repository cache key Summary: Some people have 2GB+ untracked files in repo which significantly slows down this or even crashes it. Test Plan: Added a debug output here and linted repo with untracked path. Reviewers: epriestley Reviewed By: epriestley CC: aran, Korvin, arudolph Differential Revision: https://secure.phabricator.com/D4713 --- diff --git a/src/workflow/ArcanistBaseWorkflow.php b/src/workflow/ArcanistBaseWorkflow.php index b65d3ced..13b0fd0a 100644 --- a/src/workflow/ArcanistBaseWorkflow.php +++ b/src/workflow/ArcanistBaseWorkflow.php @@ -1549,6 +1549,9 @@ abstract class ArcanistBaseWorkflow extends Phobject { $api = $this->getRepositoryAPI(); $versions = array('' => $api->getSourceControlBaseRevision()); foreach ($api->getUncommittedStatus() as $path => $mask) { + if ($mask & ArcanistRepositoryAPI::FLAG_UNTRACKED) { + continue; + } $versions[$path] = (Filesystem::pathExists($path) ? md5_file($path) : '');