/usr/share/doc/git

The Complete Git & GitHub Guide

IN PROGRESS — 40 of 75 chapters published; more on the way

CHAPTERS
75
WRITTEN
40
PARTS
11
PROGRESS
53%

A guide that teaches Git and GitHub step by step from the basics, even if you’ve never touched them before. 75 pages in 11 parts.

Git is software that records the change history of your files on your own PC. GitHub is a service for storing that history on the internet and sharing it with others. The names are similar, but they’re different things. This guide keeps the two separate, covering Git first and GitHub after.

Even if you’re someone who “pushes without really knowing what’s going on,” there’s material here that goes beyond the basics, from how Git works internally to how teams use it.

Before you start reading#

If you’re new, read in order starting from Part 1, #01 (Introduction: How to Read This Guide). It gives you a map of the whole guide and shows where to start reading depending on your goal.

If you’ve come here to look something up because you’re stuck, go straight to Part 11, #73 (Troubleshooting Index).

Git (Parts 1–5, 35 pages)#

How Git works and how to use it. Parts 2 through 5 take place entirely on your own PC; no internet connection is needed.

GitHub (Parts 6–11, 40 pages)#

Storing your local Git history on GitHub and working with other people.

PART 01Introduction — The Big Picture

Understand the difference between Git and GitHub, and set up your account. Everyone should read this part.

  1. 01Introduction: How to Read This Guide
  2. 02What Is Version Control
  3. 03Git vs. GitHub
  4. 04Creating a GitHub Account
  5. 0510 Terms You Need to Know

PART 03Git Internals — Why It Works the Way It Does

Explain what commands do by understanding the mechanics, not by memorizing. Skimming is fine on a first read.

  1. 16Git Stores Snapshots, Not Diffs
  2. 17The Four Objects (blob / tree / commit / tag)
  3. 18What Is HEAD, and Detached HEAD
  4. 19Refs and What a Branch Really Is
  5. 20A Tour of the .git Folder

PART 06Connecting to GitHub

Push your local history to the cloud and pull it back down. This is where the internet first comes in.

  1. 36The Idea of a Remote Repository
  2. 37Authenticating (HTTPS + PAT / SSH)Writing
  3. 38Creating a Repository on GitHubWriting
  4. 39Uploading with push
  5. 40Downloading with clone, fetch, and pull
  6. 41Understanding Tracking Branches (Upstream)
  7. 42Putting an Existing Project on GitHub

PART 07Collaborating on GitHub

Use issues and pull requests to build software together with others.

  1. 43Issues: Making Work VisibleWriting
  2. 44Labels, Milestones, and TemplatesWriting
  3. 45Creating a Pull RequestWriting
  4. 46Code Review in PracticeWriting
  5. 47Branch Protection and Merge MethodsWriting
  6. 48Forking and Contributing to Open SourceWriting
  7. 49Organizations and Team PermissionsWriting
  8. 50Tracking Progress with ProjectsWriting
  9. 51CODEOWNERS, Discussions, and WikiWriting

PART 08Making the Most of GitHub

Master the features around your repository: README, licenses, Pages, and more.

  1. 52Writing a READMEWriting
  2. 53GitHub Markdown and GistsWriting
  3. 54Choosing a LicenseWriting
  4. 55Shipping Versions with Releases and TagsWriting
  5. 56Publishing with GitHub PagesWriting
  6. 57Security Features (Dependabot / Secret Scanning / CodeQL)Writing
  7. 58Search, Stars, Watching, and InsightsWriting

PART 09GitHub Actions — Automation

Automate testing and deployment.

  1. 59CI/CD and GitHub Actions BasicsWriting
  2. 60Writing Workflow YAMLWriting
  3. 61Handling Secrets and VariablesWriting
  4. 62Practical RecipesWriting
  5. 63Marketplace and Reusable WorkflowsWriting
  6. 64Pricing and Run TimeWriting

PART 10Working Smarter with Tools

Speed up your daily work with GUI and CLI tools.

  1. 65Git in VS CodeWriting
  2. 66GitHub DesktopWriting
  3. 67GitHub CLI (gh)Writing
  4. 68Customizing Your Setup (config / alias / diff tools)Writing
  5. 69Working with AI (Copilot / Claude Code)Writing

PART 11Practice and Quick Answers

Build real workflows and learn to recover from trouble on your own.

  1. 70Case 1: A Solo Developer WorkflowWriting
  2. 71Case 2: A Small Team WorkflowWriting
  3. 72Case 3: Managing Documents and Settings as a Non-EngineerWriting
  4. 73Troubleshooting: Quick AnswersWriting
  5. 74Command Cheat SheetWriting
  6. 75Where to Go from HereWriting