Re: git branch --current?
- From
Jay Soffian <jaysoffian@gmail.com>
- Date
- Mar 17, 2010, 14:48 UTC
- Message-ID
- <76718491003170748h349c5ed0u7649864cc824f549@mail.gmail.com>
- In-Reply-To
- <fcaeb9bf1003170743kc347d53jefe41039e3b9a69a@mail.gmail.com>
On Wed, Mar 17, 2010 at 10:43 AM, Nguyen Thai Ngoc Duy <pclouds@gmail.com> wrote:
Show 7 quoted lines
> I use "git branch" when I need to know the current branch. But I have > many branches, looking for the star is "time consuming". I'd rather > have something like pwd, just print the current branch name and that's > all. A bit more information about current branch wouldn't hurt, as > long as the branch name is printed at a fixed location. > > What command do you use to know what branch you are on?
Doesn't everyone who's anyone put it in their prompt with the bash completion script? :-)
Well, if not, how about a simple alias:
pwb = rev-parse --abbrev-ref HEAD
?
j.