What is version control

[I]s the management of changes to documents […] Changes are usually identified by a number or letter code, termed the “revision number”, “revision level”, or simply “revision”. For example, an initial set of files is “revision 1”. When the first change is made, the resulting set is “revision 2”, and so on. Each revision is associated with a timestamp and the person making the change. Revisions can be compared, restored, and with some types of files, merged. – Wiki Diagram of version control

Why do we care

Have you ever:

In these cases, and no doubt others, a version control system should make your life easier.

Stackoverflow (by si618)


Git: The stupid content tracker

Git logo

How can I use Git

There are several ways to include Git in your work-pipeline. A few are:

More alternatives here.


A Common workflow

Git workflow
A common git workflow
  1. Start the session by pulling (possible) updates: git pull

  2. Make changes

    1. (optional) Add untracked (possibly new) files: git add [target file]

    2. (optional) Stage tracked files that were modified: git add [target file]

    3. (optional) Revert changes on a file: git checkout [target file]

  3. Move changes to the staging area (optional): git add

  4. Commit:

    1. If nothing pending: git commit -m "Your comments go here."

    2. If modifications not staged: git commit -a -m "Your comments go here."

  5. Upload the commit to the remote repo: git push.