D6082: phabricator: add a `--branch` flag to `hg phabsend`
pulkit (Pulkit Goyal)
phabricator at mercurial-scm.org
Tue Mar 19 07:24:52 EDT 2019
pulkit added a comment.
In https://phab.mercurial-scm.org/D6082#88981, @Kwan wrote:
> In https://phab.mercurial-scm.org/D6082#88852, @mharbison72 wrote:
> > In https://phab.mercurial-scm.org/D6082#88851, @pulkit wrote:
> > > @mharbison72 thanks for tips on adding test. Will add tests in next iteration.
> > >
> > > I found that Differentials do have a branch field, maybe we can use that? https://secure.phabricator.com/source/phabricator/browse/master/src/applications/differential/customfield/DifferentialBranchField.php
> > Seems worth a shot. I don’t know anything about it, but presumably this would be rendered specially in the web UI, like the test plan, etc. That sounds better than as a follow up comment. It also seems natural enough that maybe it can be done unconditionally, instead of needing the argument.
> Yeah, it shows in the Diff Detail pane, like here <https://phabricator-dev.allizom.org/D1092?id=1765>. Unfortunately I think it can be only set when using the creatediff endpoint, which is what I had to change my fork to do (though I could be wrong, the conduit docs are too sparse to be sure).
Last night I tried different endpoints and looks like creatediff is the only one which can be used to set the branch. I have asked on their discourse https://discourse.phabricator-community.org/t/conduit-api-to-set-branch-of-a-differential/2521.
Talking about creatediff, can it be used instead of createrawdiff? It it's possible can you paste the changes you did your fork, maybe we need the exact same changes.
In https://phab.mercurial-scm.org/D6082#89250, @indygreg wrote:
> While there may be a need for an explicit `--branch` argument, should we start by having `hg phabsend` automatically pick up the branch from the changeset? i.e. wouldn't we want branch selection to be automatic?
Yes I agree. The next version of this patch will make `hg phabsend` automatically pick up the branch from changeset.
To: pulkit, #hg-reviewers
Cc: indygreg, Kwan, mharbison72, mercurial-devel
More information about the Mercurial-devel