From: Junio C Hamano Date: Fri, 26 Dec 2025 02:11:49 GMT Subject: Re: Why git branch --show-current ignores -v? Message-ID: In-Reply-To: Junio C Hamano writes: > Sergey Organov writes: > >> It looks useful and natural for "git branch --show-current -v[v]" to >> verbosely describe current branch, similar to what --list does. Is there >> sound reason why -v is not supported by --show-current? > > The "--show-current" feature was invented merely for those who > somehow found it ugly to use "git symbolic-ref HEAD" when a user > wants to learn what the current branch was. If I have to guess, > nobody thought about it as a way to get the same output as "--list" > but restricted to the single current branch. Hence nobody felt the > need to support any option that the "--list" operation supported, > including "-v". IOW, nobody shared your "It looks useful" so far, > especially among the people who knew where the "--show-current" > option came from. > > I do not think anybody terribly objects if somebody teaches "-v" to > make "git branch --show-current" more verbose, and other "--list" > operations in general, but I suspect that the exact contents in the > verbose output may have to be different from that of "--list". For > one thing, as "--show-current" limits its output to the current > branch, the two-place indent "git branch --list" gives its output is > not there, and "-v" would probably not want to add it. Forgot to say something much more important. Commands should complain when users give them input that they do not understand. If "git branch --show-current -v" silently eats "-v", I would say it is a bug. Unless we define that the current output is already verbose, that is. Thanks.