Skip to Main Content
Pragmatic Guide to Git
book

Pragmatic Guide to Git

by Travis Swicegood
November 2010
Beginner content levelBeginner
160 pages
2h 50m
English
Pragmatic Bookshelf
Content preview from Pragmatic Guide to Git
32 Comparing Differences

Git’s log provides you with the information about a change—who made it, what their intent was, and so on—but sometimes looking at the changes made to the code provides more information. git diff shows you the changes that were made between two commits.

You can use git diff to view the changes—referred to as diffs or patches—of two different commits or states. Most of the time it’s called as git diff with no parameters. That’s the same as telling Git, “Show me the changes between my working tree and the staging area.”

git diff considers changes that are staged and ready to be committed as part of the repository. You can tell Git to show the differences between what is staged and what is stored in the repository ...

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Pragmatic Version Control Using Git

Pragmatic Version Control Using Git

Travis Swicegood
Git Version Control Cookbook - Second Edition

Git Version Control Cookbook - Second Edition

Kenneth Geisshirt, Emanuele Zattin(EUR), Aske Olsson, Rasmus Voss
Git for Programmers

Git for Programmers

Jesse Liberty

Publisher Resources

ISBN: 9781680500028Errata