You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: book/02-git-basics/sections/undoing.asc
+2-2Lines changed: 2 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -130,8 +130,8 @@ You can see that the changes have been reverted.
130
130
[IMPORTANT]
131
131
=====
132
132
It's important to understand that `git checkout -- <file>` is a dangerous command.
133
-
Any changes you made to that file are gone -- Git just copied another file over it.
134
-
Don't ever use this command unless you absolutely know that you don't want the file.
133
+
Any local changes you made to that file are gone -- Git just copied the most recently-committed version of that file over top of it.
134
+
Don't ever use this command unless you absolutely know that you don't want those unsaved local changes.
135
135
=====
136
136
137
137
If you would like to keep the changes you've made to that file but still need to get it out of the way for now, we'll go over stashing and branching in <<ch03-git-branching#ch03-git-branching>>; these are generally better ways to go.
0 commit comments