introduction

git is a content tracker that can work as a distributed revision control system, it was idealized and mainly made by Linus Torvalds for the source code management of the 2.6 series of the linux kernel. It is powerful and it's design follows one of the best software design philosophy: it address one problem and solves it very well.

distributed

Being distributed has strong advantages, the most obvious and probably the most advantageous is the possibility to work offline (in a plane, a car, a train, in poorly connected areas) and still has access to all your commit history, logs and branches.

The privacy comes into play too, by being distributed allows you to create any branch you want and no one will even bother, you will never mess up with a central place.

Enhancements in development cycle, git don't need network reads (except to synchronize repositories) to access the repository metadata (commit history, logs, previous versions), this fact tremendously speed up the development, you will work and think faster.

Another very important aspect of being distributed is that the distributed model is inherently more trustworthy, you don't need to grant commit access to anyone, you just fetch and merge from others, the decision to incorporate other people's code is totally up to you.

The network of trust model create by git does work for both open source projects and tightly controled corporate environments, the more trustworthy entity (project leader/manager, qa team) controls and centralizes the projects.

technical advantages

git has a series of positive aspects such as:

  • it's robust, use simple data structures

  • tagging, branching and merging are easy and natural

  • use a content-addressable database

  • can synchronize repository over well know ssh and http protocols

  • compression for storage and network transmission efficiency

  • a bare repository can work as an incremental backup

  • integrity check based on sha1 hash

  • content integrity (what you push is what you fetch)

  • fast, very fast

usage

Using git is easy, you can track a collection of files with only three commands (init, add, commit) and then you can clone the repository to and from anywhere, the synchronization is done by push and fetch commands, the merge command reflects changes that were fetched, the pull command do both fetch and merge.

Here a list of the first commands that popup from my mind:

  • init

  • add

  • commit

  • clone

  • push

  • fetch

  • merge

There are a lot of other commands and they may seen scary, but most of then you will probably never use since they are only used for git core operation, i suggest you to look after for these commands: checkout, remote, config, status, diff, branch, show-branch and reset.

documentation

git project has a high quality documentation included in the source distribution, you will find a manual, an user guide, a tutorial, a study case for important roles such as individual developer, participant developer, integrator and repository administrator, there is also a document that explains the repository layout, howtos and a tutorial about the git internals.

references

© 2007-2008 Alexandre Girão