]> khamidou — GitHub mirrors - arcanist.git/commit
Try switching to the branch of the same name, instead of detached head
authorAlex Vandiver <alexmv@dropbox.com>
Fri, 20 Nov 2015 18:55:37 +0000 (10:55 -0800)
committerAlex Vandiver <alexmv@dropbox.com>
Fri, 20 Nov 2015 18:58:37 +0000 (10:58 -0800)
commita77a77817a0399cb2c543f3a6aa03883cebf8837
treecf46e2d7bf615ae2d2b2dada0f887a422054df1a
parent2eada58960e5add9077f9f01b9d8c242b8c5f39b
Try switching to the branch of the same name, instead of detached head

Summary:
Landing from a branch that directly tracks origin/master places one in
a detached HEAD state.  Instead, examine if there is a local branch of
the name that we landed onto, that also tracks the upstream; if so,
switch to that.

Test Plan:
Made a branch via `git checkout -b testing origin/master`
and tried to `arc land`

Reviewers: epriestley, #blessed_reviewers

Reviewed By: epriestley, #blessed_reviewers

Subscribers: Korvin

Maniphest Tasks: T9723

Differential Revision: https://secure.phabricator.com/D14420
src/land/ArcanistGitLandEngine.php