Doug Bryant

Tech thoughts and notes

Getting Git +svn Branches to Follow Remote Branch

Andy Delcambre and Robby Russell both have excellent articles about getting up and running with git as an subversion client.

The one thing that had been getting me was the fact that the branch I created locally did not always stick to following the remote branch. It would start out that way, but once I checked out the master branch again, it would not always and definitely not consistently point toward the remote branch once I re-checked out my branch.

I finally figured out that the local and remote branch must be named differently. The character case matters! So if I had a remote branch of ITR-FOO and a local branch of itr-foo, it would loose track of the remote branch. The easy solution is to name the branches differently by using a “-” remotely and a “_” locally for names or just name the branches differently. Now, I use ITR-FOO remotely and itr_foo locally, or shorten the local name to itr_promos if I am using ITR-PROMOTIONS remotely.

For merging branching, using git is so much simpler, even if it is very retarded sometimes.