Free Git & GitHub Course for Developers | Version Control
Master version control with Git and GitHub — essential for every developer. Learn branching, merging, pull requests, and open source contribution.
TL;DR: Master version control with Git and GitHub — essential for every developer. Learn branching, merging, pull requests, and open source contribution.
Written & reviewed by the Syllab.in Academic Team (CBSE/NCERT subject experts) · Updated
Free Git & GitHub course: 45 lessons, from the basics through to the advanced topics interviewers actually ask about. Every lesson is free, needs no sign-up, and runs in your browser with an editor and instant AI feedback.
Git & GitHub Course Syllabus — 45 Lessons
Work through them in order, or jump to the topic you need. 45 lessons include worked explanations and runnable examples.
Git Basics
- What is Git? — Git is a version control system that tracks changes to your code over time.
- Installing Git & Configuration — Before using Git, you need to install it and configure your identity.
- git init - Start a Git Repository — `git init` creates a hidden `.git` folder in your project directory.
- git status - Check Repository Status — `git status` shows what's happening in your repository right now.
- git add - Stage Changes — `git add` stages files — it tells Git "I want to include these changes in my next commit." Staging is the step between making changes and committing them.
- git commit - Save Changes with a Message — `git commit` saves your staged changes to Git history with a message.
- git log - View Commit History — `git log` shows all commits in reverse chronological order (newest first).
- git diff - Compare Changes — `git diff` shows line-by-line what changed between versions.
- .gitignore - Exclude Files from Tracking — Not all files should be in Git. Temporary files, API keys, passwords, and large binaries like node_modules/ should be excluded.
- git stash - Temporarily Save Work — Sometimes you start working on something, then need to switch to a different task without committing.
Branching & Merging
- git branch - Create & Manage Branches — A branch is an independent line of development.
- git checkout - Switch Branches — `git checkout` switches your working directory to a different branch.
- git merge - Combine Branches — `git merge` integrates changes from one branch into another.
- Handling Merge Conflicts — Merge conflicts happen when two people edit the same part of the same file differently.
- Understanding Fast-Forward Merge — A fast-forward merge happens when the main branch hasn't changed since you created your feature branch.
- git rebase - Rewrite Commit History — Rebasing rewrites your branch's commit history on top of another branch.
- Git Branch Strategies (Git Flow & Trunk-Based) — Branch strategies are team conventions for organizing branches.
- git cherry-pick - Apply Specific Commits — Cherry-picking applies one specific commit from another branch to your current branch, without merging the entire branch.
Remote Repositories
- What is GitHub? — GitHub is a cloud platform for hosting Git repositories.
- git clone - Copy a Repository — `git clone` downloads a complete copy of a repository from GitHub (or any remote server) to your computer.
- git remote - Manage Remote Connections — `git remote` manages connections between your local repository and remote servers (like GitHub).
- git push - Upload Changes to Remote — `git push` uploads your commits to a remote repository (usually GitHub).
- git pull - Download & Integrate Remote Changes — `git pull` is the opposite of push. It downloads commits from the remote repository and integrates them into your current branch.
- git fetch - Download Without Merging — `git fetch` downloads commits from the remote but doesn't integrate them into your branch yet.
- Fork & Pull Request Workflow — When you don't have direct push access to a repository, you fork it (create your own copy), make changes in your fork, then submit a pull request asking the original owner to accept your changes.
- Upstream Remote - Keep Fork in Sync — When you fork a repository, your fork is a snapshot at that moment.
Collaboration
- Pull Request Workflow - Review & Merge — A Pull Request (PR) is a request to merge your code into main.
- Code Review & Feedback — Code review is a team process where developers examine each other's code for bugs, style, security, and performance.
- GitHub Issues - Track Bugs & Features — GitHub Issues are tickets for bugs, features, and tasks.
- GitHub Actions - Automate Testing & Deployment — GitHub Actions automatically runs tests, linters, and deployments when code is pushed or a PR is opened.
- Branch Protection Rules — Branch protection prevents accidental merges to main.
- Squash Merge - Combine Commits — Squash merge combines all commits from a feature branch into a single commit before merging to main.
- git blame - Track Code Changes by Author — git blame shows who wrote each line of code and when.
Advanced Git
- git reset - Undo Commits — git reset moves the branch pointer backwards to an earlier commit.
- git revert - Safely Undo Changes — git revert creates a NEW commit that undoes a previous commit.
- git commit --amend - Modify Last Commit — git commit --amend modifies the last commit without creating a new one.
- git reflog - Recover Lost Work — git reflog shows a log of where HEAD has been (all your recent moves).
- git bisect - Find Broken Commits — git bisect does binary search through commits to find which one introduced a bug.
- git tag - Mark Release Versions — Tags mark specific commits as important milestones, usually releases.
- git submodules - Include External Repositories — Submodules let you include another Git repository inside your project.
GitHub Features
- GitHub Pages - Host Static Websites — GitHub Pages hosts your static website (HTML, CSS, JS) for free directly from your GitHub repository.
- README.md - Document Your Project — README.md is the first file visitors see on your GitHub repository.
- GitHub Gist - Share Code Snippets — GitHub Gist is a simple way to share code snippets, configurations, or notes.
- GitHub Copilot - AI Code Assistant — GitHub Copilot is an AI that suggests code as you type.
- GitHub Projects Board - Organize Work — GitHub Projects is a Kanban board for organizing issues and PRs.
Who this Git & GitHub course is for
School and college students in India starting from zero, and anyone revising Git & GitHub for placements, board practicals or a project. There is no prerequisite beyond being able to type — the first lessons assume no programming background at all.
How to study this course
- Read the lesson, then run the example in the built-in editor before moving on — reading code is not the same as writing it.
- Try the practice task at the end of each lesson. Getting it wrong and fixing it is where the learning happens.
- When you are stuck, ask the free AI Tutor to explain that specific line rather than skipping ahead.
🤖 Stuck on any of these? Ask Syllab's free AI Tutor to explain step by step →