English subtitles

← Cloning and Exploring The Repo Solution - How to Use Git and GitHub

Get Embed Code
5 Languages

Showing Revision 3 created 05/25/2016 by Udacity Robot.

  1. To find the commit which reverted the controls, first I'll type git log.
  2. Now, I don't see a commit with the message revert controls yet, so
  3. I'll press the down arrow and scroll down.
  4. And here it is.
  5. Since I found it, I'll press Q to quit out of git log.
  6. So this is the commit ID of the commit that reverted the controls.
  7. It starts with b067.
  8. Now I want to see how many lines were introduced in this commit.
  9. Remember that the changes introduced by this commit will be
  10. different from the previous commit.
  11. So, I can copy this commit ID, type git diff and
  12. paste it, and then I'll copy and paste this commit ID.
  13. Now I can just count up the lines that have changed.
  14. So far, there's two insertions and two deletions.
  15. We'll scroll down.
  16. Another insertion and deletion, so that's three each.
  17. Another, so four each.
  18. And I'll press Q to quit git diff.
  19. So, the correct commit ID started with b067 and
  20. there were four lines added and four lines deleted by that commit.