Git
Pre-requisites: A computer, Internet, know how to open command line.
Imagine you have a program. A simple script called helloworld.cpp
.
It is working quite as intended and you’re completely happy with the way it works. But, you decide to add a feature.
Now, when you write more code in helloworld.cpp
there is a chance that the program which was working perfectly earlier, will stop working. You don’t want to risk losing the earlier perfect code, so you make a copy of helloworld.cpp
before you write more code into it.
Now you have two files. helloworld-old.cpp
and helloworld.cpp
.
If you add 5 more features, you might end up with 5 files.
Git is a version controlling system
It automatically makes backups of all the crime code that you commit. It lets you branch out and explore new possibilities. (If it turns out that you didn’t like what you added, you can just jump back to the main branch.)
Install git
Follow this guide on git-scm.com to install git