git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "Jørgen Edelbo" <jed@napatech.com>
To: Phil Hord <phil.hord@gmail.com>
Cc: "git@vger.kernel.org" <git@vger.kernel.org>,
	Johannes Sixt <j.sixt@viscovery.net>,
	Junio C Hamano <gitster@pobox.com>,
	Heiko Voigt <hvoigt@hvoigt.net>, <patthoyts@gmail.com>
Subject: Re: [PATCH] git-gui: Modify push dialog to support Gerrit review
Date: Sat, 7 Sep 2013 19:03:53 +0200	[thread overview]
Message-ID: <522B5C79.3000107@napatech.com> (raw)
In-Reply-To: <CABURp0qL6CSmt87OnTpRjS4VFikfA3O+w7-HgfB9d6Kip46EpA@mail.gmail.com>

On 06-09-2013 23:49, Phil Hord wrote:
> 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".

My first attemt at this change was to do do exactly that: always push 
HEAD, and being able to specify the destination branches. If it was a 
Gerrit review server, it would replace refs/heads/... with refs/for/...

However, it is now clear, that we have to support specifying the 
branches to push.

My next thought was: could we add an entry to the list of branches to 
push, meaning "omit the branch specs in the command". Then it should 
just perform a "git push <remote>". What was then pushed would depend
on the push configuration for the remote. In the Gerrit case we could 
then have:
   push = HEAD:refs/for/master, or whatever.

The drawback of this solution is that the UI is not so intuitive and it 
would not support the case where you would want to push your branch 
frotz to refs/for/master/frotz, which is the way you specify a topic in 
Gerrit. The current solution supports this.

What remains to support is the case where you work on a detached HEAD. 
Most of it should be straight forward. The gui knows we are in detached 
state, so in this case, a "HEAD" entry could be added to the list of 
branches. The question is just: to which branch to push to in the non 
Gerrit case? Perhaps the ref specs could just be left out in this case.

  reply	other threads:[~2013-09-07 17:13 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-09-06 10:30 [PATCH] git-gui: Modify push dialog to support Gerrit review Joergen Edelbo
2013-09-06 21:49 ` Phil Hord
2013-09-07 17:03   ` Jørgen Edelbo [this message]
  -- strict thread matches above, loose matches on Subject: below --
2013-09-12  9:21 Joergen Edelbo
2013-09-02  8:54 Joergen Edelbo
2013-09-05  6:20 ` Heiko Voigt
2013-09-05  6:42 ` Johannes Sixt
2013-09-05  8:29   ` Jørgen Edelbo
2013-09-05  8:57     ` Johannes Sixt
2013-09-05  9:18       ` Jørgen Edelbo
2013-09-05  9:31         ` Johannes Sixt
2013-09-05 17:34         ` Junio C Hamano
2013-09-06  8:17           ` Jørgen Edelbo
2013-09-05 18:19 ` Junio C Hamano

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=522B5C79.3000107@napatech.com \
    --to=jed@napatech.com \
    --cc=git@vger.kernel.org \
    --cc=gitster@pobox.com \
    --cc=hvoigt@hvoigt.net \
    --cc=j.sixt@viscovery.net \
    --cc=patthoyts@gmail.com \
    --cc=phil.hord@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).