]> khamidou — GitHub mirrors - arcanist.git/commit
Fix "arc lint" when HEAD has been reverted in the working copy
authorepriestley <git@epriestley.com>
Wed, 29 Feb 2012 20:18:46 +0000 (12:18 -0800)
committerepriestley <git@epriestley.com>
Wed, 29 Feb 2012 20:18:46 +0000 (12:18 -0800)
commitf9a7cb225ef49814cfd90d71e89e2de0300a0cf5
treebb1c9affd37797300133b061b90eaeb0f8d6b336
parentb3a70ac2069f2de0fa79eb5849d7841cdb643a4e
Fix "arc lint" when HEAD has been reverted in the working copy

Summary:
If a user reverts HEAD in the index or working copy, "git diff" shows no changes
and we explode.

Instead, we should simply return no changes; the rest of the lint pipeline
accommodates this correctly.

Test Plan: Reverted HEAD in a working copy, ran "arc lint", got an error.
Applied patch, ran "arc lint", got accurate lint.

Reviewers: Koolvin, btrahan

Reviewed By: Koolvin

CC: aran, epriestley
Differential Revision: https://secure.phabricator.com/D1729
src/repository/api/git/ArcanistGitAPI.php
src/repository/api/mercurial/ArcanistMercurialAPI.php