On Fri, Nov 27, 2009 at 1:00 PM, Konstantin Khomoutov
<khomou...@gmail.com> wrote:
> On Nov 26, 11:23 am, itroot <ivan.tolstoshe...@gmail.com> wrote:
>> Some branches in git are tracking another branches (for example,
>> usually master tracks origin/master). Let's assume, that in my work-
>> flow i don't want accidentally commit in master, but i want master to
>> track origin/master. I release that i can do this with hooks, but this
>> solution seems to me complicated.
>> Can i make some git branches const?
> I think you can not, but until you have pushed the branch with wrongly
> applied commits
> you can easily revert these wrong changes using `git reset --
> hard ...`,
> so the absence of immutable branches is not a big loss.
> On the other hand, Git already includes certain things which are there
> mostly
> for convenience, so why not.
> In either case, you should suggest your idea on the official Git
> mailing list, not here.

I think that by definition a branch is a movable pointer to a commit,
so a const branch is a bit of an oxymoron.

The concept for a fixed pointer to a commit is called a tag.  If I
want to mark a point I might want to get back to, such as the commit
corresponding to a current release, the I tag it and push the tag.

Rick DeNatale

Blog: http://talklikeaduck.denhaven2.com/
Twitter: http://twitter.com/RickDeNatale
WWR: http://www.workingwithrails.com/person/9021-rick-denatale
LinkedIn: http://www.linkedin.com/in/rickdenatale


You received this message because you are subscribed to the Google Groups "Git 
for human beings" group.
To post to this group, send email to git-us...@googlegroups.com.
To unsubscribe from this group, send email to 
For more options, visit this group at 

Reply via email to