]> khamidou — GitHub mirrors - arcanist.git/commit
Fix "arc lint" exploding on new directories
authorepriestley <git@epriestley.com>
Thu, 3 Nov 2011 20:42:19 +0000 (13:42 -0700)
committerepriestley <git@epriestley.com>
Thu, 3 Nov 2011 21:28:04 +0000 (14:28 -0700)
commitd57ea379c6cb8de17ca118561aaca702b524301e
tree700edb733a4e378afd2bd92d3869b194a550f6b8
parent59cd94d8ebca57999b18d954bbfbbc2b0e0a0268
Fix "arc lint" exploding on new directories

Summary:
D1061 introduced a 'text file' check, but it fails under SVN for new
directories.

  - Revert D1061 (This reverts commit b2cd18252701be2093b52652fb3d1d94c5df571e.)
  - Make getChangedLines() return null to indicate that the operation doesn't
make sense. I think this was the intent of the code in the lint engine.
  - Fix a bug where running "arc lint" on a change in an SVN working copy from a
subdirectory would fail.
  - Fix a bug where warnings with no line information were incorrectly
discarded.

Test Plan:
  - Ran "arc lint" in an SVN working copy with a new directory (no failure).
  - Forced FilenameLinter to always raise a warning. Added a binary file and ran
"arc lint". The warning was reported for the new binary file, a new text file,
and a new directory.

Reviewers: jungejason, andrewjcg, nh, tuomaspelkonen, aran

Reviewed By: andrewjcg

CC: aran, andrewjcg, epriestley
Differential Revision: 1076
src/lint/engine/base/ArcanistLintEngine.php
src/repository/api/subversion/ArcanistSubversionAPI.php
src/workflow/base/ArcanistBaseWorkflow.php
src/workflow/lint/ArcanistLintWorkflow.php