From: Andreas Ericsson Date: Thu, 30 Oct 2008 15:25:50 GMT Subject: Re: Using the --track option when creating a branch Message-ID: <4909D1FE.2080403@op5.se> In-Reply-To: <2008-10-30-16-04-08+trackit+sam@rfc1149.net> Samuel Tardieu wrote: > * Andreas Ericsson [2008-10-30 15:54:53 +0100] > >> Correct me if I'm wrong, but wouldn't my suggestion of not trying to >> push (even matching) branches that haven't been updated since we last >> fetched from the remote do exactly the same thing for your particular >> use-case, but without syntax change and all the annoying minor parts >> that it entails? > > Not exactly. I often do some work on a branch which does not mandate > a topic branch and have to switch branches to fix a bug for example. > This would continue to push unterminated changes as well. > > Typical use case, which happens (to me) quite frequently: > ... > > Argh, "master" has been pushed as well. Ok, I could have done > Ah, I see. I sympathize, although I really do think you'd be better off by learning to explicitly push things. > % git branch > (because I know I am on the right branch but do not necessarily > remember its full name all the time) offtopic: Use shell-completion and set your PS1 to include the __git_ps1 output. > % git push origin 2.0-beta1-release-candidate > > or I could have started a topic branch, but I often push 2 or 3 > commits at a time instead, the first one being a refactoring of > existing code to ease the subsequent one. > I fail to see why this would prevent you from starting a topic-branch. In fact, I would have thought it was a reason *for* starting a topic. >>From what I have seen, people I am working with often have the > same workflow (do not systematically start a topic branch when > in active development mode) > >> Define "many". Perhaps as often as 2-3 times per day. Not very often, >> but frequent enough that I definitely want some short sweet way of >> doing it. OTOH, I also find the "rejected" messages annoying, and I >> definitely feel one could do something about them. However, it's my >> birthday today and I plan on being far too drunk/hungover the entire >> weekend for me to take any actions in that direction. > > Happy birthday :) > Thank you :-) -- Andreas Ericsson andreas.ericsson@op5.se OP5 AB www.op5.se Tel: +46 8-230225 Fax: +46 8-230231