Thread (3 messages) flat view 3 messages, 3 authors, 2016-06-15

Re: Re: [PATCH] git-gui: give more advice when detaching HEAD

From: Heiko Voigt <hidden>
Date: 2016-06-15 22:50:35

Possibly related (same subject, not in this thread)

Hi,

On Tue, Feb 15, 2011 at 07:48:33PM +0000, Pat Thoyts wrote:
From: Heiko Voigt <redacted>
Date: Tue, 15 Feb 2011 19:43:54 +0000
Subject: [PATCH] git-gui: warn when trying to commit on a detached head

The commandline is already warning when checking out a detached head.
Since the only thing thats potentially dangerous is to create commits
on a detached head lets warn in case the user is about to do that.

Signed-off-by: Heiko Voigt <redacted>
Signed-off-by: Pat Thoyts <redacted>
---
[...]
My feeling is that the user should be making a branch to hold his
commits. So I suggest adding some text to suggest that a branch be
created and keep annoying the user every time they commit to a detached
head. This errs on the side of not dropping commits into the reflog
which seems the most useful strategy to me.

So here is a modded version of Heiko's patch.
Thanks for cleaning up my wording. I would be fine with this patch.
I played with creating a dialog including a checkbox yesterday. Please
see my other answer to this thread whether we work on this further.
Otherwise I would be fine with just issuing the warning every time. Its
better than not warning at all and using the configuration option a
clueful person can still disable the warning.

Cheers Heiko

P.S.: Should I prepare a separate patch to document the variable for
      Junio once he pulls again from you?
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help