All of lore.kernel.org
 help / color / mirror / Atom feed
From: Junio C Hamano <gitster@pobox.com>
To: Jeff King <peff@peff.net>
Cc: "Junio C Hamano" <gitster@pobox.com>,
	"Sverre Rabbelier" <srabbelier@gmail.com>,
	"Ævar Arnfjörð" <avarab@gmail.com>,
	git@vger.kernel.org
Subject: Re: What's cooking in git.git (Feb 2011, #06; Sun, 27)
Date: Tue, 01 Mar 2011 18:07:29 -0800	[thread overview]
Message-ID: <7vlj0yff6m.fsf@alter.siamese.dyndns.org> (raw)
In-Reply-To: <20110301205424.GA18793@sigill.intra.peff.net> (Jeff King's message of "Tue\, 1 Mar 2011 15\:54\:24 -0500")

Jeff King <peff@peff.net> writes:

> On Mon, Feb 28, 2011 at 08:52:08AM -0800, Junio C Hamano wrote:
>
>> I am not convinced that this patch nailed that balance at exactly the
>> right place, even though I think we are getting closer than before.  In
>> this sequence:
>> 
>>     $ git checkout somewhere^0
>>     $ git commit
>>     $ git reset --hard somewhere_else
>>     $ git commit
>>     $ git checkout master
>> ...
> I really wouldn't expect it to help here. The problem isn't that you're
> on a detached HEAD. It's that you're using "git reset" at all.

As you would realize later in your message, the "reset --hard" can instead
be "checkout v1.7.3".  And the bothersome thing is that there is no safety
against that.  We don't bother users while they are jumping around on
detached HEAD, and it is not new; we don't say where the previous detached
HEAD was.

Perhaps that needs to be changed to have the same safety?  IOW, regardless
of your "checkout" destination, whenever you leave a detached commit that
would become unreachable, we should warn the same way?

I suspect I would loath it as being too loud; I dunno...

  reply	other threads:[~2011-03-02  2:07 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-02-28  6:48 What's cooking in git.git (Feb 2011, #06; Sun, 27) Junio C Hamano
2011-02-28 13:22 ` Sverre Rabbelier
2011-02-28 16:52   ` Junio C Hamano
2011-03-01 20:54     ` Jeff King
2011-03-02  2:07       ` Junio C Hamano [this message]
2011-03-02 21:27         ` Jeff King
2011-03-02  5:24       ` Junio C Hamano
2011-03-02  7:17         ` Piotr Krukowiecki
2011-03-02 10:32           ` Jakub Narebski
2011-03-10  9:44             ` Ævar Arnfjörð Bjarmason
2011-03-10 16:37               ` Jakub Narebski
2011-03-02 21:28         ` Jeff King

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=7vlj0yff6m.fsf@alter.siamese.dyndns.org \
    --to=gitster@pobox.com \
    --cc=avarab@gmail.com \
    --cc=git@vger.kernel.org \
    --cc=peff@peff.net \
    --cc=srabbelier@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.