Git development
 help / color / mirror / Atom feed
From: Johannes Schindelin <Johannes.Schindelin@gmx.de>
To: Junio C Hamano <gitster@pobox.com>
Cc: "Karl Hasselström" <kha@treskal.com>,
	"Gerrit Pape" <pape@smarden.org>,
	git@vger.kernel.org
Subject: Re: [PATCH] git-bisect.sh: don't accidentally override existing branch "bisect"
Date: Sat, 3 May 2008 13:48:52 +0100 (BST)	[thread overview]
Message-ID: <alpine.DEB.1.00.0805031347460.30431@racer> (raw)
In-Reply-To: <7v8wysy5bz.fsf@gitster.siamese.dyndns.org>

[-- Attachment #1: Type: TEXT/PLAIN, Size: 1362 bytes --]

Hi,

On Fri, 2 May 2008, Junio C Hamano wrote:

> Karl Hasselström <kha@treskal.com> writes:
> 
> > On 2008-04-30 16:46:13 +0000, Gerrit Pape wrote:
> >
> >> If a branch named "bisect" or "new-bisect" already was created in the 
> >> repo by other means than git bisect, doing a git bisect used to 
> >> override the branch without a warning. Now if the branch "bisect" or 
> >> "new-bisect" already exists, and it was not created by git bisect 
> >> itself, git bisect start fails with an appropriate error message. 
> >> Additionally, if checking out a new bisect state fails due to a merge 
> >> problem, git bisect cleans up the temporary branch "new-bisect".
> >
> > Makes me wonder why bisect has to use a branch at all, and not just a 
> > detached HEAD ... I seem to recall this having been discussed before, 
> > but I can't find it now.
> 
> Only because the mechanism predates detached HEAD and no other reason. 
> Whoever wants to update it to use detached HEAD needs to design what 
> should happen when the bisection was started while the HEAD is detached 
> (should we come back to the same HEAD?  how? ...), but other than that I 
> do not offhand see fundamental difficulties.

IMO it should behave as the rebase machinery does: record $(git rev-parse 
HEAD) in the case of a detached HEAD, and go back to that.  It is dead 
easy.

Ciao,
Dscho

      reply	other threads:[~2008-05-03 12:49 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-04-30 16:46 [PATCH] git-bisect.sh: don't accidentally override existing branch "bisect" Gerrit Pape
2008-04-30 21:30 ` Christian Couder
2008-05-01 12:15   ` Richard Quirk
2008-05-01 12:27     ` Christian Couder
2008-05-02  8:56   ` [PATCH amend] " Gerrit Pape
2008-05-03  8:42     ` Christian Couder
2008-05-05  7:43       ` Gerrit Pape
2008-05-06  6:20         ` Christian Couder
2008-05-02  8:22 ` [PATCH] " Karl Hasselström
2008-05-02 17:38   ` Junio C Hamano
2008-05-03 12:48     ` Johannes Schindelin [this message]

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=alpine.DEB.1.00.0805031347460.30431@racer \
    --to=johannes.schindelin@gmx.de \
    --cc=git@vger.kernel.org \
    --cc=gitster@pobox.com \
    --cc=kha@treskal.com \
    --cc=pape@smarden.org \
    /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