Switch from SVN to GIT

I've been using github.com and bitbucket.com for a while now, but less than a year ago, the development group i'm with decided to switch to GIT.  And I was nervous due to the fact that most of the work I did was in solitaire on github and bitbucket.  I never really was on the opposite end where I was managing and supporting other developers with GIT.

But Ignoring my nerves, I started to really review best (or common) practices of GIT and how the distributed nature of it.  The distributed nature still scares me a little, due to the fact that one developer could really F'up the central repository (depending on your setup).  Atlassian's Stash was chosen as the GIT managing server, that is due to the fact that it adds features to GIT that you would normally have to do manually.  I'll jump into Atlassian's Stash a little later.  For now, just the SVN to GIT conversion.

There are a lot of tutorials on how to migrate your SVN repository into GIT, my article isn't to guide you through that, but rather the common developer's gotchas because you have to think slightly different when using GIT versus SVN.

The big gotcha that keeps getting me, is that it is distributed.  A commit is only local, no other developer will see it until it is "pushed", to a central or other GIT repository.  The next gotcha is language itself that comes around GIT.  Commit, Push, pull, and fetch are common terminology behind GIT, make sure you read the definitions and understand them.

Lastly, the last gotcha that I keep having is along with the distributed model.  You need to remember to keep your local repository updated with the other "central" repository.

The last thing I would like to point out is having a defined "workflow" for you GIT repositories is key.  Due to the fact that GIT is distributed, you can do a lot of work in a different fashion. There is NOT a one fit all mentality here but there is a solution for everyone, just look around.  Here are some resources for GIT workflows:

GIT is flexible and can be adjusted as you go.  Put a vision in place for the workflow and take small implementations of that vision.  In my opinion the transition from SVN to GIT using GIT workflows will greatly impact your development practices.

Comments

Popular posts from this blog

ColdFusion in an Enterprise Environment - Part 1 - Understanding how to use SubVersion (SVN)

coldfusion builder 2 extension not displaying browse button on type=projectdir

Being Thread Safe in Coldbox/Coldfusion