Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions book/02-git-basics/sections/undoing.asc
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ $ git add forgotten_file
$ git commit --amend
----

You end up with a single commit the second commit replaces the results of the first.
You end up with a single commit -- the second commit replaces the results of the first.

[NOTE]
====
Expand Down Expand Up @@ -97,7 +97,7 @@ We'll go into much more detail about what `reset` does and how to master it to d
==== Unmodifying a Modified File

What if you realize that you don't want to keep your changes to the `CONTRIBUTING.md` file?
How can you easily unmodify it revert it back to what it looked like when you last committed (or initially cloned, or however you got it into your working directory)?
How can you easily unmodify it -- revert it back to what it looked like when you last committed (or initially cloned, or however you got it into your working directory)?
Luckily, `git status` tells you how to do that, too.
In the last example output, the unstaged area looks like this:

Expand Down Expand Up @@ -130,7 +130,7 @@ You can see that the changes have been reverted.
[IMPORTANT]
=====
It's important to understand that `git checkout -- <file>` is a dangerous command.
Any changes you made to that file are gone Git just copied another file over it.
Any changes you made to that file are gone -- Git just copied another file over it.
Don't ever use this command unless you absolutely know that you don't want the file.
=====

Expand Down