Git & Version Control Fundamentals

Lesson 1 of 5

Introduction to Git

Git is a distributed version control system, it tracks every change to your code over time, lets you go back to any previous state, and makes it possible for multiple people to work on the same project without stepping on each other's changes.

Why use version control?

  • History, every commit is a snapshot you can return to.
  • Branching, try risky changes on a separate line of work without touching the working code.
  • Collaboration, merge everyone's work together instead of emailing zip files around.

Installing Git and setting your identity

Check whether Git is already installed:

git --version

Every commit is stamped with an author, so set your identity once per machine:

git config --global user.name "Your Name"
git config --global user.email "you@example.com"

--global applies these settings to every repository on your machine, not just the current one.

📝 Git Basics

Passing score: 70%
  1. 1.What type of software is Git?

  2. 2.Git and GitHub are the same thing.

  3. 3.The command to set your Git username globally is: git config --global user.____