]> khamidou — GitHub mirrors - arcanist.git/commitdiff
Restore default "yes" behavior for lint patch
authorAiden Scandella <ai@uber.com>
Tue, 11 Aug 2015 21:49:48 +0000 (14:49 -0700)
committerepriestley <git@epriestley.com>
Tue, 11 Aug 2015 21:49:56 +0000 (14:49 -0700)
Summary:
Fixes T9029

See T9029 for more details, but basically at some point phutil_console_confirm
(which takes a `$default_no` parameter) was refactored to `$console->confirm()`
which takes a `$default` parameter with semantics negated..

Test Plan:
Run `arc lint` on a repository where patch is suggested. Default
option should be "[Y/n]" to accept the patch.

Reviewers: joshuaspence, #blessed_reviewers, epriestley

Reviewed By: #blessed_reviewers, epriestley

Subscribers: epriestley

Maniphest Tasks: T9029

Differential Revision: https://secure.phabricator.com/D13873

src/workflow/ArcanistLintWorkflow.php

index f1578c37d8d483c10e5fd46007a3515e76dc2547..27db427d54facf9f4297f654712582cb8d52a94d 100644 (file)
@@ -526,7 +526,7 @@ EOTEXT
           $prompt = pht(
             'Apply this patch to %s?',
             phutil_console_format('__%s__', $result->getPath()));
-          if (!$console->confirm($prompt, $default_no = false)) {
+          if (!$console->confirm($prompt, $default = true)) {
             continue;
           }
         }