small medium large xlarge

Pragmatic Guide to Git


Cover image for Pragmatic Guide to Git

Pragmatic Guide to Git


Need to learn how to wrap your head around Git, but don’t need a lot of hand holding? Grab this book if you’re new to Git, not to the world of programming. Git tasks displayed on two-page spreads provide all the context you need, without the extra fluff.

Choose Your Format(s)

  • $32.00 In Stock

    Save $11.00 on the combo pack.

  • $25.00 In Stock
  • $18.00 In Stock
  • Ebooks are DRM free.

  • Ebook delivery options.

About this Title

Pages: 160
Published: 2010-11-01
Release: P3.0 (2012-03-27)
ISBN: 978-1-93435-672-2

Get up to speed on Git right now with Pragmatic Guide to Git. Here you’ll find the 95 percent of Git that you’ll use at least once a week, as well as a few tasks that will come in handy but aren’t used as often.

Task-oriented two-page spreads get you up and running with minimal fuss. Each left-hand page dives into the underlying implementation for each task. The right-hand page contains commands that focus on the task at hand, and cross references to other tasks that are related. You’ll find what you need fast.

Git is rapidly becoming the de-facto standard for the open source community. Its excellent merging capabilities, coupled with its speed and relative ease of use, make it an indispensable tool for any developer. New Git users will learn the basic tasks needed to work with Git every day, including working with remote repositories, dealing with branches and tags, exploring the history, and fixing problems when things go wrong. If you’re already familiar with Git, this book will be your go-to reference for Git commands and best practices.

You won’t find a more practical approach to learning Git than Pragmatic Guide to Git.

Read the reviews .

Contents & Extracts

For more information on the Pragmatic Guide Series, please see the faq

Full Table of Contents


  • Getting Started
    • Task 1. Installing Git
    • Task 2. Configuring Git
    • Task 3. Creating a New Repository
    • Task 4. Creating a Local Copy of an Existing Repository
  • Working with Git excerpt
    • Task 5. Seeing What Has Changed
    • Task 6. Staging Changes to Commit
    • Task 7. Committing Changes
    • Task 8. Ignoring Files
    • Task 9. Undoing Uncommitted Changes
    • Task 10. Moving Files in Git
    • Task 11. Deleting Files in Git
    • Task 12. Sharing Changes
  • Organizing Your Repository with Branches and Tags
    • Task 13. Creating and Switching Branches
    • Task 14. Viewing Branches
    • Task 15. Merging Commits Between Branches
    • Task 16. Rewriting History by Rebasing
    • Task 17. Deleting Branches
    • Task 18. Tagging Milestones
  • Working with a Team
    • Task 19. Adding and Removing Remotes
    • Task 20. Retrieving Remote Changes
    • Task 21. Retrieving Remote Changes, Part II
    • Task 22. Sending Changes to Remote
    • Task 23. Handling Remote Tags and Branches
  • Branches and Merging Revisited
    • Task 24. Handling Conflicts
    • Task 25. Handling Conflicts with a GUI
    • Task 26. Temporarily Hiding Changes
    • Task 27. Cherry-Picking Commits
    • Task 28. Controlling How You Replay Commits
    • Task 29. Moving Branches
  • Working with the Repository’s History excerpt
    • Task 30. Viewing the Log
    • Task 31. Filtering the Log Output
    • Task 32. Comparing Differences
    • Task 33. Generating Statistics About Changes
    • Task 34. Assigning Blame
  • Fixing Things
    • Task 35. Fixing Commits
    • Task 36. Reverting Commits
    • Task 37. Resetting Staged Changes and Commits
    • Task 38. Erasing Commits
    • Task 39. Finding Bugs with bisect
    • Task 40. Retrieving “Lost” Commits
  • Moving Beyond the Basics
    • Task 41. Exporting Your Repository
    • Task 42. Doing Some Git Housekeeping
    • Task 43. Syncing with Subversion
    • Task 44. Initializing Bare Repositories


Travis Swicegood is a professional programmer; owner of Domain51, a web and mobile development company in Lawrence, Kansas; and the author of Pragmatic Version Control Using Git, the first published book on Git. He’s passionate about open source development and is active in communities across several languages.