We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 056e752 commit 6db9f27Copy full SHA for 6db9f27
git_cheat_sheet.md
@@ -330,15 +330,15 @@
330
git reset HEAD
331
git reset HEAD -- <single-file>
332
333
-* Discard all local changes in your working directory
334
-
335
- git reset --hard HEAD
336
337
* Discard local changes in a specific file
338
339
git checkout <file>
340
341
-* Revert a commit
+* Discard all local changes in your working directory
+
+ git reset --hard HEAD
+* Revert a commit (e.g. to revert a commit already pushed to remote)
342
343
git revert HEAD
344
git revert <commit>
0 commit comments