git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH] git-gui: Modify push dialog to support Gerrit review

From
Phil Hord <phil.hord@gmail.com>
Date
Sep 6, 2013, 21:49 UTC
Message-ID
<CABURp0qL6CSmt87OnTpRjS4VFikfA3O+w7-HgfB9d6Kip46EpA@mail.gmail.com>
In-Reply-To
<20130906105022.0718C12156D@jed-dev-01.labnet>
On Fri, Sep 6, 2013 at 6:30 AM, Joergen Edelbo <jed@napatech.com> wrote:
Show 9 quoted lines
> Problem: It is not possible to push for Gerrit review as you will
> always try to push to "refs/heads/..." on the remote.
>
> Changes done:
>
> Add an option to select "Gerrit review" and a corresponding entry
> for a branch name. If this option is selected, push the changes to
> "refs/for/<gerrit-branch>/<local branch>". In this way the local branch
> names will be used as topic branches on Gerrit.
In my gerrit repos, I have this configuration
  $  git config remote.origin.push HEAD:refs/for/master
And so I can simply 'git push' and git does what I mean.

My main complaint with git-gui's push is that it ignores my configuration. Can you teach git-gui to honor this setting, instead?

I would like for this remote."name".push option to be smarter and figure out which $branch I mean when I am not on master, but that is a different discussion. Having said that, I see that your change to git-gui attempts to make that automatic. Kudos for that, but I don't think this will work for me as I am often on a detached branch and so "refs/heads/$b" is meaningless.

Can you think of a sane way to separate the "from" and the "to" branches in the GUI? I mean, I would like to push "HEAD" and I would like it to go to "refs/for/frotz-2.0".

Phil
Previous: Joergen EdelboNext: Jørgen Edelbo
Message 2 of 3 in “git-gui: Modify push dialog to support Gerrit review”
  1. git-gui: Modify push dialog to support Gerrit reviewJoergen Edelbo, Sep 6, 2013
  2. Phil HordSep 6, 2013
  3. Jørgen EdelboSep 7, 2013

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.