Skip to content

GitHub Comparison Guide

Purpose

Compare branches before integrating changes.

Local Git Commands

  • git diff: Inspect differences.
  • git log: Inspect commit history.
  • git merge-base: Find the common ancestor.
  • git rev-list: Count commits unique to each side.

GitHub Compare

GitHub Compare allows developers to inspect:

  • Commits
  • Changed files
  • Added lines
  • Removed lines
  • Differences between branches