Tuesday, November 26, 2013

Why Git is a better VCS ?

Notes to self from an excellent article: http://www.gitology.com/chapter/benefits-of-using-git

Git makes your life easier.
It's that simple.
You might say, "That sounds appealing, but how does it make my life easier?" Well, it turns out that Git makes your life easier in a number of ways.
First, Git empowers you to make commits any time you feel like it, even when you're not connected to the network. That's pretty great. Say, you're on an airplane, or doing a some extra work on the train ride home from work, and you're at a perfect point to do a commit before moving on to the next batch of work. If you're using a centralized VCS, like Subversion, you're stuck if you can't connect to the server. You simply can't commit until you get somewhere where you have connectivity. With Git, you can commit immediately, network or no network. (Not to mention other tasks such as branching, merging, et cetera.)

Second, Git has cheap branching and merging. Though other VCSes have branching and merging, Git's branching is so good and so well implemented, you'll actually use branches frequently, and it'll make your life better. I think you'll be surprised how great it is, and how "cheap" it is (in terms of effort and complexity). 
 
Third, Git enables you to use more flexible workflows that help you work better, smarter, and with less overall stress. T

Aside from making your life easier, Git has a number of other benefits, including:
  • Data redundancy and replication -- Since there are multiple full repositories on multiple machines (instead of one central repository), the risk of project loss due to server failure or some other catastrophe is much lower.
  • High availability -- Server down? Network down? No problem. Work in your repo (commit, view history, branch, etc) to your heart's content. Try that with Subversion!
  • Only one .git directory per repository -- Versus a .svn in every subfolder, which, as you may know from painful personal experience, can lead to problems.
  • Superior disk utilization and network performance
  • Properties such as ignores are much easier to manage than in Subversion
  • Collaboration Friendly -- Git makes it easy to collaborate on projects with groups of contributors. And with great services like Github, Git's collaboration friendliness is even further magnified.
  • Not just for code! -- Git is great for all sorts of projects, not just hacking code. For example, all of Gitology's written content is managed with Git, not just it's code.