System that records changes made to a set of files over time
These systems are called VCS (Version Control Systems)
They are essential to programming projects involving several people
Keep every version of a file (source code, image...)
Work easily with several programmers
Revert files back to a previous state
Compare changes over time
And much more...
Local
Centralised
Distributed
Simple local database
No connectivity
No collaboration
Example: RCS
Made for dealing with the collaboration issue
One single remote server
Requires to know what other people are doing
Examples: CVS, Subversion
Full local copy of the remote repository
Can deal with several remote repositories
Several types of workflows
It's fast
Strong support of non-linear workflows
Ables to handle large projects efficiently
Most used VCS these days
Free and open source
To initialise a Git repository in an existing directory:
git init
And to create a new one:
git init my-project
If you want a copy of an existing Git repository:
git clone git@github.com:docker/docker.git
The above command line will clone the official repository of the Docker project
To track new files:
git add *.c
git add include/
git add README.md
These files are now in the staging area
And now, your first commit:
git commit -m "first commit"
Git's "killer feature"
Incredibly lightweight
Designed to be used as often as possible
Centralised
Integration manager
Dictator and lieutenant
Public clouds
Self-hosted servers
Git is not GitHub!
Generally free for public repositories
Better choice if your work is confidential
Manage privileges
Pull requests / Merge requests
Issues
Wiki
Webhooks