]> khamidou — GitHub mirrors - arcanist.git/commitdiff
Explicitly provide "--ff" when performing squash merges in "arc land" under Git
authorepriestley <git@epriestley.com>
Wed, 28 Oct 2015 23:46:39 +0000 (16:46 -0700)
committerepriestley <git@epriestley.com>
Thu, 29 Oct 2015 00:13:15 +0000 (17:13 -0700)
Summary: Ref T3855. See discussion leading up to T3855#142304.

Test Plan: See T3855#142304.

Reviewers: chad

Reviewed By: chad

Maniphest Tasks: T3855

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

src/land/ArcanistGitLandEngine.php

index f2b5d63230c309f6d68b1b4d92bd0b9978ebc604..95b33aa1f05739b2480c5be190932abe242ea19d 100644 (file)
@@ -148,8 +148,11 @@ final class ArcanistGitLandEngine
 
     try {
       if ($this->getShouldSquash()) {
+        // NOTE: We're explicitly specifying "--ff" to override the presence
+        // of "merge.ff" options in user configuration.
+
         $api->execxLocal(
-          'merge --no-stat --no-commit --squash -- %s',
+          'merge --no-stat --no-commit --ff --squash -- %s',
           $source);
       } else {
         $api->execxLocal(
@@ -200,7 +203,7 @@ final class ArcanistGitLandEngine
       pht('PUSHING'),
       pht('Pushing changes to "%s".', $this->getTargetFullRef()));
 
-    list($err) = $api->execPassthru(
+    $err = $api->execPassthru(
       'push -- %s %s:%s',
       $this->getTargetRemote(),
       $this->mergedRef,