2009/2/10 Junio C Hamano <gitster@pobox.com>:
quoted text > Mark Burton <markb@ordern.com> writes:
>
>> Johannes Schindelin <Johannes.Schindelin@gmx.de> wrote:
>>> Let's hope that nobody's scripts rely on a single star in front of the
>>> local HEAD...
>>
>> I don't know if I have any scripts that rely on a single star in front of
>> the local HEAD or not (I'm sure some people must have them), but I do
>> think this new feature would be very confusing, especially when used
>> with -a.
>
> People use "git branch | sed -ne 's/^\* //p' in their scripts (you can say
> "against recommendation" but I think it is a sign that the recommendation
> against use of Porcelain in the scripts is not loud enough). I do not
> think anybody greps in "git branch -a", though, for that purpose.
>
> The current "branch -a" output is a mess. It omits "remotes/" even though
> it includes the local ones in the output. Perhaps with remotes/, the
> output may become a bit more readable:
>
> $ git branch -a
> * master
> next
> pu
> * remotes/dscho/master
> * remotes/origin/master
> remotes/origin/next
> remotes/origin/pu
> * remotes/spearce/master
>
> which may still be too loud with asterisks, but at least there is no
> confusion. Or perhaps like this:
>
> $ git branch -a
> * master
> next
> pu
> remotes/dscho/HEAD -> master
> remotes/dscho/master
> remotes/origin/HEAD -> master
> remotes/origin/master
> remotes/origin/next
> remotes/origin/pu
> remotes/spearce/HEAD -> master
> remotes/spearce/master
>
> with an obvious twist when there is no mixed output:
>
> $ git branch -r
> dscho/HEAD -> master
> dscho/master
> origin/HEAD -> master
> origin/master
> origin/next
> origin/pu
> spearce/HEAD -> master
> spearce/master
For me it makes sense.
Also this type of output for symrefs "-> master" makes even more sense
in the verbose output.
Santi
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to
majordomo@vger.kernel.org
More majordomo info at
http://vger.kernel.org/majordomo-info.html