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

Re: [PATCH] checkout: warn about 'branch name' rather than 'local branch'

From: Nicolas Pitre <nico@fluxnic.net>
Date: 2016-06-15 22:48:08

Possibly related (same subject, not in this thread)

On Fri, 29 Jan 2010, Sverre Rabbelier wrote:
These days, you can say "git checkout topic" to automagically create
a local "topic" branch that forks from "origin/topic" remote tracking
branch when you have one, thanks to Dscho's UI improvement ideas. As
such it is more appropriate to say that the user is checking out
something that is not a branch name, rather than saying it is not a
'local branch'.

Signed-off-by: Sverre Rabbelier <redacted>
For the record, I'm providing a NAK.  First I don't agree with the UI 
"improvement" if there is no way to check out a remote branch without 
creating soon-to-be-stall local branches with the same name.

Next, the message can be made yet more clear and give the user more of a 
hint with what is going on.  Something like:

	"%s is not a local branch head: creating a detached HEAD\n"

plus the remaining clue lines.  This way people will have a much greater 
chance of understanding what state they're in, and a simple Google 
search for detached HEAD gives you the Git manual page with the needed 
info.


Nicolas
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help