Page MenuHomePhabricator

"arc patch" should be applied against the branch it is based on, instead of master branch
Closed, DeclinedPublic

Description

Steps to reproduce

Actual results

  • i'm not sure but it seems when I do arc patch D234 it applies the patch. But when I arc diff to update the diff it seems to includes all the files that have been changed, for example I think it is applying the patch against the master branch not against the branch it is based on or the current branch your on.

Expected results

  • Applying the patch should use the branch you uploaded it with not the master branch. Since I have to do remember todo --nobranch now so it apples on the branch I want t to based on. Since there are many changes between master and wmf/stable branch doing arc diff uploads all the changes due to differences between the branches.

Event Timeline

Paladox renamed this task from Doing arc patch dosent work properly to Doing arc patch dosent work properly, it dosent use the correct branch.May 24 2016, 8:15 AM
Aklapper renamed this task from Doing arc patch dosent work properly, it dosent use the correct branch to "arc patch" should be applied against the branch it is based on, instead of master branch.May 24 2016, 8:33 AM

Could you please edit "Actual results" by splitting it into several sentences with punctuation, so it is easier to read and understand for others? Thank you!

And you should be able to apply it against the current branch your on so if to git checkout wmf/stable it should be applied against that branch.

https://secure.phabricator.com/book/phabricator/article/arcanist_commit_ranges/

In Git and Mercurial, many arc commands (notably, arc diff) operate on a range of commits beginning with some commit you specify and ending with the working copy state.

Since the end of the range is fixed (the working copy state), you only need to specify the beginning of the range. This is called the "base commit". You can do this explicitly when you run commands:

$ arc diff HEAD^ # git: just the most recent commit

Oh, is there a way we can get it to do it behind the scenes like gerrit. Since it checkouts out the branch that has the revision.