]> khamidou — GitHub mirrors - arcanist.git/commitdiff
Allow upgrading in branch `stable`
authorAviv Eyal <avivey@gmail.com>
Mon, 7 Sep 2015 20:44:47 +0000 (13:44 -0700)
committerepriestley <git@epriestley.com>
Mon, 7 Sep 2015 20:44:48 +0000 (13:44 -0700)
Summary: close T9043. This still allows for one dir to be in `master` and the other in `stable`, but hopefully that's not going to be a problem.

Test Plan: Clone arc/libph, checkout `stable`, run arc upgrade.

Reviewers: #blessed_reviewers, epriestley

Reviewed By: #blessed_reviewers, epriestley

Subscribers: cburroughs, epriestley

Maniphest Tasks: T9043

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

src/workflow/ArcanistUpgradeWorkflow.php

index ed30593f0937be0b661387cebd750860b93a2e98..c9e0e8587899119a7ac3e341abf9081a4bfa12dd 100644 (file)
@@ -53,18 +53,18 @@ EOTEXT
 
       $this->setRepositoryAPI($repository);
 
-      // Require no local changes.
       $this->requireCleanWorkingCopy();
 
-      // Require the library be on master.
       $branch_name = $repository->getBranchName();
-      if ($branch_name != 'master') {
+      if ($branch_name != 'master' && $branch_name != 'stable') {
         throw new ArcanistUsageException(
           pht(
-            "%s must be on branch '%s' to be automatically upgraded. ".
+            "%s must be on either branch '%s' or '%s' to be automatically ".
+            "upgraded. ".
             "This copy of %s (in '%s') is on branch '%s'.",
             $lib,
             'master',
+            'stable',
             $lib,
             $root,
             $branch_name));